]> granicus.if.org Git - php/commitdiff
MFH: initialize vars
authorAntony Dovgal <tony2001@php.net>
Mon, 10 Jul 2006 11:26:22 +0000 (11:26 +0000)
committerAntony Dovgal <tony2001@php.net>
Mon, 10 Jul 2006 11:26:22 +0000 (11:26 +0000)
ext/date/php_date.c

index a31a8dbd92c442137e956576d3ab39f9e9e32a4e..7fb4767aedeb00e8eb96dbb7af7a4264dea18411 100644 (file)
@@ -696,7 +696,7 @@ static char *date_format(char *format, int format_len, timelib_time *t, int loca
        smart_str            string = {0};
        int                  i;
        char                 buffer[33];
-       timelib_time_offset *offset;
+       timelib_time_offset *offset = NULL;
        timelib_sll          isoweek, isoyear;
        int                  rfc_colon = 0;
 
@@ -878,7 +878,7 @@ PHPAPI int php_idate(char format, time_t ts, int localtime)
        timelib_time   *t;
        timelib_tzinfo *tzi;
        int retval = -1;
-       timelib_time_offset *offset;
+       timelib_time_offset *offset = NULL;
        timelib_sll isoweek, isoyear;
 
        t = timelib_time_ctor();
@@ -1120,7 +1120,7 @@ PHPAPI void php_mktime(INTERNAL_FUNCTION_PARAMETERS, int gmt)
 {
        long hou, min, sec, mon, day, yea, dst = -1;
        timelib_time *now;
-       timelib_tzinfo *tzi;
+       timelib_tzinfo *tzi = NULL;
        long ts, adjust_seconds = 0;
        int error;
 
@@ -1253,7 +1253,7 @@ PHPAPI void php_strftime(INTERNAL_FUNCTION_PARAMETERS, int gmt)
        size_t               buf_len = 64, real_len;
        timelib_time        *ts;
        timelib_tzinfo      *tzi;
-       timelib_time_offset *offset;
+       timelib_time_offset *offset = NULL;
 
        timestamp = (long) time(NULL);