ID: 38908 User updated by: golikov at hotmail dot com Reported By: golikov at hotmail dot com -Status: Feedback +Status: Open Bug Type: Variables related Operating System: Linux (2.6.9-34.0.2.ELsmp) PHP Version: 5.1.6 New Comment:
I don't have any Linux system available to build and test. The bug is visible on a hosting. Can you get someone else to test? BTW I forgot my pswd and mails on forgotten pswd do not come through. Previous Comments: ------------------------------------------------------------------------ [2006-09-23 11:43:18] [EMAIL PROTECTED] Please try using this CVS snapshot: http://snaps.php.net/php5.2-latest.tar.gz For Windows: http://snaps.php.net/win32/php5.2-win32-latest.zip Not reproducible. ------------------------------------------------------------------------ [2006-09-21 04:14:46] golikov at hotmail dot com Description: ------------ If big negative number (-3032250090012579) is converted to integer, php 5.1.6 does not overflow on LINUX and uses max negative integer value (-2147483648) instead. Though on Windows it works as ok. Related bug #30315. Reproduce code: --------------- $a2 = 2224955379988029; echo "$a2 => (int)" . (int)$a2 . "\n"; $a3 = -2224955379988029; echo "$a3 => (int)" . (int)$a3 . "\n"; Expected result: ---------------- 2.224955379988E+015 => (int)-888097219 -2.224955379988E+015 => (int)888097219 Actual result: -------------- 2.22495537999E+15 => (int)-888097219 -2.22495537999E+15 => (int)-2147483648 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=38908&edit=1