Bug #1088: occasional failure of bitwise &
| From: | jda at dct dot com | Date: | Thu, 21 Jan 1999 21:44:54 +0000 |
| Subject: | Bug #1088: occasional failure of bitwise & | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-3676@lists.php.net to get a copy of this message | ||
From: jda@dct.com
Operating system: Solaris 2.6
PHP version: 3.0.5
PHP Bug Type: Misbehaving function
Bug description: occasional failure of bitwise &
if (!$z) { $z = 0; }
if (($z != 1) && ($z != 2) && ($z != 4) && ($z != 8) && ($z != 16)
&&
($z !=32)) { $z = 0; }
if ($z == ($z & $thiscookie)) { $z = 0; }
$thiscookie += $z;
Tracing the value of $z through the above results in strange errors on the third line, where the
following has occurred:
(a) $z=4, $thiscookie=59, if statement evaluated true and reset $z to 0.
(b) $z=1, $thiscookie=58, if statement evaluated true and reset $z to 0.
--
PHP Development Mailing List http://www.php.net/
To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net
For help: php-dev-help@lists.php.net