From 7599f7384b8c80d8b3c34d2053b6c25ecd7ba348 Mon Sep 17 00:00:00 2001 From: Derick Rethans Date: Fri, 2 May 2008 21:32:13 +0000 Subject: [PATCH] - Fixed an issue in date() where a : was printed for the O modifier after a P modifier was used. --- ext/date/php_date.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ext/date/php_date.c b/ext/date/php_date.c index a80b21304f..b6a4eb9c2e 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -903,7 +903,7 @@ static char *date_format(char *format, int format_len, int *return_len, timelib_ timelib_time_offset *offset = NULL; timelib_sll isoweek, isoyear; php_locale_data *loc_dat; - int rfc_colon = 0; + int rfc_colon; if (!format_len) { if (UG(unicode)) { @@ -940,6 +940,7 @@ static char *date_format(char *format, int format_len, int *return_len, timelib_ for (i = 0; i < format_len; i++) { no_free = 0; + rfc_colon = 0; switch (format[i]) { /* day */ case 'd': length = date_spprintf(&buffer, 32 TSRMLS_CC, "%02d", (int) t->d); break; -- 2.50.1