diff --git a/inc/config.php b/inc/config.php index 6d1a8081..b17f55de 100644 --- a/inc/config.php +++ b/inc/config.php @@ -1103,6 +1103,7 @@ $config['error']['toomanycross'] = _('Too many cross-board links; post discarded.'); $config['error']['nodelete'] = _('You didn\'t select anything to delete.'); $config['error']['noreport'] = _('You didn\'t select anything to report.'); + $config['error']['invalidreport'] = _('The reason was too long.'); $config['error']['toomanyreports'] = _('You can\'t report that many posts at once.'); $config['error']['invalidpassword'] = _('Wrong password…'); $config['error']['invalidimg'] = _('Invalid image.'); diff --git a/post.php b/post.php index 47c5f0ef..01b2ef6e 100644 --- a/post.php +++ b/post.php @@ -287,6 +287,9 @@ if (isset($_POST['delete'])) { if (empty($report)) error($config['error']['noreport']); + + if (strlen($report) > 30) + error($config['error']['invalidreport']); if (count($report) > $config['report_limit']) error($config['error']['toomanyreports']);