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

# will MFH to 5.0.X and 4.3.X after release

ext/standard/datetime.c

index 21075cde1b45229f55f4f99bcb7ec8bfd1ff637a..b327c346c288522b3db711a250948dc5b95d2a3b 100644 (file)
@@ -949,7 +949,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],