diff options
Diffstat (limited to 'phpBB/posting.php')
| -rw-r--r-- | phpBB/posting.php | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/phpBB/posting.php b/phpBB/posting.php index 663a96591f..9b33a9ab62 100644 --- a/phpBB/posting.php +++ b/phpBB/posting.php @@ -1130,12 +1130,17 @@ if ($config['enable_post_confirm'] && !$user->data['is_registered'] && $solved_c $confirm_id = md5(unique_id($user->ip)); $seed = hexdec(substr(unique_id(), 4, 10)); + if ($seed > 0x7FFFFFFF) + { + $seed -= 0x7FFFFFFF; + } + $sql = 'INSERT INTO ' . CONFIRM_TABLE . ' ' . $db->sql_build_array('INSERT', array( 'confirm_id' => (string) $confirm_id, 'session_id' => (string) $user->session_id, 'confirm_type' => (int) CONFIRM_POST, 'code' => (string) $code, - 'seed' => (float) $seed) + 'seed' => (int) $seed) ); $db->sql_query($sql); |
