diff options
author | Andreas Fischer <bantu@phpbb.com> | 2011-03-05 22:20:23 +0100 |
---|---|---|
committer | Andreas Fischer <bantu@phpbb.com> | 2011-03-05 22:59:23 +0100 |
commit | c6c2a23ecb10b4b54e7e9b703d14e8c7cda6ad55 (patch) | |
tree | e93f8757cfe96d0ac995458a58240e07a1dd9db8 | |
parent | 5ab4dc298327d3a8d51387959d6905c6bb24fd99 (diff) | |
download | forums-c6c2a23ecb10b4b54e7e9b703d14e8c7cda6ad55.tar forums-c6c2a23ecb10b4b54e7e9b703d14e8c7cda6ad55.tar.gz forums-c6c2a23ecb10b4b54e7e9b703d14e8c7cda6ad55.tar.bz2 forums-c6c2a23ecb10b4b54e7e9b703d14e8c7cda6ad55.tar.xz forums-c6c2a23ecb10b4b54e7e9b703d14e8c7cda6ad55.zip |
[ticket/10042] GD CAPTCHA: Round offset to the next pixel.
PHPBB3-10042
-rw-r--r-- | phpBB/includes/captcha/captcha_gd.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/phpBB/includes/captcha/captcha_gd.php b/phpBB/includes/captcha/captcha_gd.php index 96e39af85b..7a3f4f46ab 100644 --- a/phpBB/includes/captcha/captcha_gd.php +++ b/phpBB/includes/captcha/captcha_gd.php @@ -77,7 +77,7 @@ class captcha { $denom = ($code_len - $i); $denom = max(1.3, $denom); - $offset[$i] = mt_rand(0, (1.5 * $width_avail) / $denom); + $offset[$i] = mt_rand(0, (int) round((1.5 * $width_avail) / $denom)); $width_avail -= $offset[$i]; } |