1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-08-11 03:04:09 +02:00

Merge branch 'ticket/rxu/9478' into develop-olympus

* ticket/rxu/9478:
  [ticket/9478] Validate maximum number of allowed recipients per PM value.
This commit is contained in:
Andreas Fischer
2010-10-25 21:52:50 +02:00
2 changed files with 15 additions and 0 deletions

View File

@@ -394,6 +394,15 @@ class acp_groups
}
}
// Validate the length of "Maximum number of allowed recipients per private message" setting.
// We use 16777215 as a maximum because it matches MySQL unsigned mediumint maximum value
// which is the lowest amongst DBMSes supported by phpBB3
if ($max_recipients_error = validate_data($submit_ary, array('max_recipients' => array('num', false, 0, 16777215))))
{
// Replace "error" string with its real, localised form
$error = array_merge($error, array_map(array(&$user, 'lang'), $max_recipients_error));
}
if (!sizeof($error))
{
// Only set the rank, colour, etc. if it's changed or if we're adding a new