|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2009-08-27 20:49 UTC] hjones at hopone dot net
[2009-08-27 21:27 UTC] derick@php.net
[2009-08-28 17:42 UTC] srinatar@php.net
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Fri Oct 24 12:00:01 2025 UTC |
Description: ------------ Upgrading from 5.2.9 to 5.2.10 causes setcookie() to return the year '0000' instead of '2009' when used with time() as the cookie expiry. Replacing 5.2.10's ext/date/php_date.{c,h} with 5.2.9's copy and recompiling corrects this issue. I believe this is a regression caused by PHP bug #48058 Reproduce code: --------------- <?php setcookie("php_test_cookie", "test_cookie_value", time() + 1444000); ?> Expected result: ---------------- Set-Cookie: php_test_cookie=test_cookie_value; expires=Sun, 13-Sep-2009 11:31:54 GMT Actual result: -------------- Set-Cookie: php_test_cookie=test_cookie_value; expires=Sun, 13-Sep-0000 11:31:54 GMT