ID: 50930 Updated by: j...@php.net Reported By: nathan dot kessler at hushmail dot me -Status: Open +Status: Assigned Bug Type: Date/time related Operating System: SuSE 7.3 i386 / gcc version 2.95 PHP Version: 5.2.12 -Assigned To: +Assigned To: jani New Comment:
This is same thing as reported in bug #50899 and since this is much better report, closing that one in favor of this. llabs() is C99, so I guess that ancient GCC does not support it. I'd suggest upgrading the compiler as first thing you do. Many other things will break in future PHP versions as well if you stick with that. :) I'll look into this, but since I don't have such old compiler around, this might take a while. Previous Comments: ------------------------------------------------------------------------ [2010-02-03 21:17:35] nathan dot kessler at hushmail dot me Description: ------------ Right after updating 5.2.11 to 5.2.12 all phpscripts using date(function showed wrong years: 2008 is 8624294332376 2009 is 8628589299673 2010 is 8632884266970 2011 is 8637179234267 2012 is 8641474201564 I reviewed patches of 5.2.12 and identified patch #50266 / revision 291371. If I compile without revision 291371 all years are fine. I see no definition of llabs in my systems /usr/include/stdlib.h like described in #50266. Perhaps this function is defined only under solaris? Reproduce code: --------------- <?php echo date( 'Y' ); ?> Expected result: ---------------- 2010 Actual result: -------------- 8632884266970 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=50930&edit=1