diff options
| author | Ilia Alshanetsky <iliaa@php.net> | 2009-06-25 12:41:41 +0000 |
|---|---|---|
| committer | Ilia Alshanetsky <iliaa@php.net> | 2009-06-25 12:41:41 +0000 |
| commit | ac88f10ea04a44d5c8a63cd7eef691b4eed86a23 (patch) | |
| tree | ad1b69c54737321a4daa7dc08e60693cf286e67a | |
| parent | 068eac20efcd1b87700fcce6d2d1b82294ea01a4 (diff) | |
| download | php-git-ac88f10ea04a44d5c8a63cd7eef691b4eed86a23.tar.gz | |
Fixed bug #48678 (DateInterval segfaults when unserialising)
| -rw-r--r-- | ext/date/php_date.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/date/php_date.c b/ext/date/php_date.c index fa0b303344..507a7875c0 100644 --- a/ext/date/php_date.c +++ b/ext/date/php_date.c @@ -2316,6 +2316,10 @@ static HashTable *date_object_get_properties_interval(zval *object TSRMLS_DC) props = intervalobj->std.properties; + if (!intervalobj->initialized) { + return props; + } + #define PHP_DATE_INTERVAL_ADD_PROPERTY(n,f) \ MAKE_STD_ZVAL(zv); \ ZVAL_LONG(zv, intervalobj->diff->f); \ |
