]> granicus.if.org Git - php/commitdiff
Avoid double-free.
authorIlia Alshanetsky <iliaa@php.net>
Wed, 15 Jun 2005 23:30:20 +0000 (23:30 +0000)
committerIlia Alshanetsky <iliaa@php.net>
Wed, 15 Jun 2005 23:30:20 +0000 (23:30 +0000)
ext/date/php_date.c

index d3e56e1b9bd1830f9ec0060c21af6ca91d67af85..35e13c66e5fc685f156c5f4204cefb6e7cc155f9 100644 (file)
@@ -141,6 +141,9 @@ PHP_FUNCTION(strtotime)
        if (now->tz_info == tzi) {
                now->tz_info = NULL;
        }
+       if (t->tz_info == tzi) {
+               t->tz_info = NULL;
+       }
 
        timelib_time_dtor(now); 
        timelib_time_dtor(t);