]> granicus.if.org Git - php/commitdiff
MFH: Fixed bug #31056 (php_std_date() returns invalid formatted date if
authorIlia Alshanetsky <iliaa@php.net>
Thu, 16 Dec 2004 00:12:56 +0000 (00:12 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Thu, 16 Dec 2004 00:12:56 +0000 (00:12 +0000)
y2k_compliance is On).

NEWS
ext/standard/datetime.c

diff --git a/NEWS b/NEWS
index 4b35d8aba4af9ba589bc30b13b630b3ca4827e77..b4b89972ac30b353657e39c7bf3260dca29a3cc2 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,6 +1,8 @@
 PHP                                                                        NEWS
 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
 ?? ??? 2005, PHP 5.0.4
+- Fixed bug #31056 (php_std_date() returns invalid formatted date if 
+  y2k_compliance is On). (Ilia)
 
 15 Dec 2004, PHP 5.0.3
 - Added the %F modifier to *printf to render a non-locale-aware representation
index 694668198dcc8434459d27e016963ffac2a80566..88b1b480f1cc81935e95de0f9c23bfc52d4f7c92 100644 (file)
@@ -945,7 +945,7 @@ char *php_std_date(time_t t TSRMLS_DC)
        tm1 = php_gmtime_r(&t, &tmbuf);
        str = emalloc(81);
        if (PG(y2k_compliance)) {
-               snprintf(str, 80, "%s, %02d-%s-%04d %02d:%02d:%02d GMT",
+               snprintf(str, 80, "%s, %02d %s %04d %02d:%02d:%02d GMT",
                                day_short_names[tm1->tm_wday],
                                tm1->tm_mday,
                                mon_short_names[tm1->tm_mon],