]> granicus.if.org Git - php/commitdiff
Fixed problem in IntlCalendar debug handler
authorGustavo André dos Santos Lopes <cataphract@php.net>
Fri, 25 May 2012 09:55:50 +0000 (11:55 +0200)
committerGustavo André dos Santos Lopes <cataphract@php.net>
Fri, 25 May 2012 11:29:19 +0000 (13:29 +0200)
*is_temp was not being set.

Also deleted a redundant assignment to *is_temp in IntlTimeZone.

ext/intl/calendar/calendar_class.cpp
ext/intl/timezone/timezone_class.cpp

index 43cbc4af856a2e5cb864b369f5b13bac86c1cf97..130c6b59f32c67c44edfb8759dfcbcc16d694a8d 100644 (file)
@@ -143,6 +143,8 @@ static HashTable *Calendar_get_debug_info(zval *object, int *is_temp TSRMLS_DC)
        Calendar_object *co;
        const Calendar  *cal;
        
+       *is_temp = 1;
+
        array_init_size(&zv, 8);
 
        co  = (Calendar_object*)zend_object_store_get_object(object TSRMLS_CC);
@@ -204,8 +206,6 @@ static HashTable *Calendar_get_debug_info(zval *object, int *is_temp TSRMLS_DC)
 
        add_assoc_zval_ex(&zv, "fields", sizeof("fields"), zfields);
 
-       *is_temp = 1;
-
        return Z_ARRVAL(zv);
 }
 /* }}} */
index a1a9866eed7cf14e84c06fe954196caa94b37d77..4034838f97ae34755e520f265817679647e7dd01 100644 (file)
@@ -395,8 +395,6 @@ static HashTable *TimeZone_get_debug_info(zval *object, int *is_temp TSRMLS_DC)
        add_assoc_long_ex(&zv, "currentOffset", sizeof("currentOffset"),
                (long)(rawOffset + dstOffset));
 
-       *is_temp = 1;
-
        return Z_ARRVAL(zv);
 }
 /* }}} */