From 7ec341cbc3e4cff4999332c9db44deef533f15b3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ermal=20Lu=E7i?= Date: Wed, 10 Feb 2010 19:27:44 +0000 Subject: [PATCH] Ticket #350. Correct calculation to be the same as in the voucher_auth. --- etc/inc/voucher.inc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/inc/voucher.inc b/etc/inc/voucher.inc index 2db6d19229..b348fc1e68 100644 --- a/etc/inc/voucher.inc +++ b/etc/inc/voucher.inc @@ -323,7 +323,7 @@ function voucher_used_count($roll) { for ($i = 1; $i <= $max; $i++) { // check if ticket already used or not. $pos = $i >> 3; // divide by 8 -> octet - $mask = 1 << (($i % 8)-1); // mask to test bit in octet + $mask = 1 << ($i % 8); // mask to test bit in octet if (ord($bitstring[$pos]) & $mask) $used++; }