]> granicus.if.org Git - php/commitdiff
- MFH: Make sure the tzcache' dtor doesn't cleanup cached misses in the lookup
authorDerick Rethans <derick@php.net>
Mon, 10 Oct 2005 16:42:32 +0000 (16:42 +0000)
committerDerick Rethans <derick@php.net>
Mon, 10 Oct 2005 16:42:32 +0000 (16:42 +0000)
  tables.

ext/date/php_date.c

index 555615c4eaf7b5f9e01fac0cc68b5e6954084e63..1d8214b125a04b4ade6d4a7182e78801ea0eb8a2 100644 (file)
@@ -190,7 +190,9 @@ static void _php_date_tzinfo_dtor(void *tzinfo)
 {
        timelib_tzinfo **tzi = (timelib_tzinfo **)tzinfo;
 
-       timelib_tzinfo_dtor(*tzi);
+       if (*tzi) {
+               timelib_tzinfo_dtor(*tzi);
+       }
 }
 
 /* {{{ PHP_RINIT_FUNCTION */