From 9ad97cd48903ea5454853960f2c14de326e0f624 Mon Sep 17 00:00:00 2001 From: Christopher Jones Date: Wed, 14 Aug 2013 20:36:50 -0700 Subject: Reduce (some) compile noise of 'unused variable' and 'may be used uninitialized' warnings. --- ext/date/php_date.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'ext/date/php_date.c') diff --git a/ext/date/php_date.c b/ext/date/php_date.c index 270c05832d..f091fed182 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -997,7 +997,7 @@ char *php_date_short_day_name(timelib_sll y, timelib_sll m, timelib_sll d) static char *date_format(char *format, int format_len, timelib_time *t, int localtime) { smart_str string = {0}; - int i, length; + int i, length = 0; char buffer[97]; timelib_time_offset *offset = NULL; timelib_sll isoweek, isoyear; @@ -2409,8 +2409,8 @@ PHPAPI int php_date_initialize(php_date_obj *dateobj, /*const*/ char *time_str, timelib_time *now; timelib_tzinfo *tzi = NULL; timelib_error_container *err = NULL; - int type = TIMELIB_ZONETYPE_ID, new_dst; - char *new_abbr; + int type = TIMELIB_ZONETYPE_ID, new_dst = 0; + char *new_abbr = NULL; timelib_sll new_offset; if (dateobj->time) { -- cgit v1.2.1