From: [EMAIL PROTECTED] Operating system: aix 4.3.3.0 PHP version: 4.2.3 PHP Bug Type: Math related Bug description: 0+0=4G on aix4.3 (64bits)
Script: <? echo '0+0=', 0+0, "\n"; ?> Output of script on php 4.2.3: 0+0=4294967294 which is equal to 2^32-2 (Output of script on php 4.1.2 and 4.0.6: 0+0=4294967296 which is equal to 2^32). In general, all simple additions and multiplications produce huge numbers: 0+0=4294967294 0+1=4294967295 1+0=4294967295 1+1=4294967296 0-0=0 0-1=-1 1-0=1 1-1=0 0*0=3.5178585246345E+18 0*1=3.5178585265101E+18 1*0=3.5178585265101E+18 1*1=3.5178585283857E+18 0/1=0 1/1=1 2/1=2 2/2=1 Installation issues # gcc -v Reading specs from /usr/local/lib/gcc-lib/rs6000-ibm-aix4.3.3.0/2.95.3/specs gcc version 2.95.3 20010315 (release) # make -v GNU Make version 3.79.1, by Richard Stallman and Roland McGrath. Built for rs6000-ibm-aix4.3.3.0 # tar -xf apache_1.3.20.tar # cd apache_1.3.20 # ./configure --enable-module=most # cd .. # tar -xf php-4.2.3.tar # cd php-4.2.3 # ./configure --without-mysql --with-apache=../apache_1.3.20 --enable-static --with-iodbc=/usr/local --enable-track-vars # make # make install # cd .. # cd apache_1.3.20 # configure --enable-module=most --activate-module=src/modules/php4/libphp4.a # make # make install I don't know if it is very relevant but the rs6000 on which aix4.3 is running is a 64bits machine. The c program int main() { printf("long=%dbits\n",8*sizeof(long)); return 0; } outputs 'long=64bits' when compiled with 'cc -q64', while when compiled with 'gcc' it outputs 'long=32bits'. Thanks very much in advance, Rein van Vliet -- Edit bug report at http://bugs.php.net/?id=20542&edit=1 -- Try a CVS snapshot: http://bugs.php.net/fix.php?id=20542&r=trysnapshot Fixed in CVS: http://bugs.php.net/fix.php?id=20542&r=fixedcvs Fixed in release: http://bugs.php.net/fix.php?id=20542&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=20542&r=needtrace Try newer version: http://bugs.php.net/fix.php?id=20542&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=20542&r=support Expected behavior: http://bugs.php.net/fix.php?id=20542&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=20542&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=20542&r=submittedtwice register_globals: http://bugs.php.net/fix.php?id=20542&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=20542&r=php3 Daylight Savings: http://bugs.php.net/fix.php?id=20542&r=dst IIS Stability: http://bugs.php.net/fix.php?id=20542&r=isapi