]> granicus.if.org Git - php/commitdiff
- Fixed a segfault - simply a forgotten return;
authorDerick Rethans <derick@php.net>
Wed, 16 Jul 2008 12:35:11 +0000 (12:35 +0000)
committerDerick Rethans <derick@php.net>
Wed, 16 Jul 2008 12:35:11 +0000 (12:35 +0000)
ext/date/php_date.c

index 5a1226a3929b637b9f3489588a7d79c75273e110..19cb877bb4e97dee7f22a75026212d882e8d0123 100644 (file)
@@ -2928,6 +2928,7 @@ PHP_FUNCTION(date_timezone_set)
        tzobj = (php_timezone_obj *) zend_object_store_get_object(timezone_object TSRMLS_CC);
        if (tzobj->type != TIMELIB_ZONETYPE_ID) {
                php_error_docref(NULL TSRMLS_CC, E_WARNING, "Can only do this for zones with ID for now");
+               return;
        }
        timelib_set_timezone(dateobj->time, tzobj->tzi.tz);
        timelib_unixtime2local(dateobj->time, dateobj->time->sse);