]> granicus.if.org Git - php/commitdiff
- Check for legal key types
authorMarcus Boerger <helly@php.net>
Sun, 12 Sep 2004 12:23:16 +0000 (12:23 +0000)
committerMarcus Boerger <helly@php.net>
Sun, 12 Sep 2004 12:23:16 +0000 (12:23 +0000)
ext/standard/var_unserializer.re

index 531fcef8c88abe4528a76b32ee74d33a1c2473f4..d70f957a7e3380de11ab30815a627af5092a85c1 100644 (file)
@@ -207,7 +207,12 @@ static inline int process_nested_data(UNSERIALIZE_PARAMETER, HashTable *ht, int
                        case IS_STRING:
                                zend_hash_update(ht, Z_STRVAL_P(key), Z_STRLEN_P(key) + 1, &data, sizeof(data), NULL);
                                break;
-
+                       default:
+                               zval_dtor(key);
+                               FREE_ZVAL(key);
+                               zval_dtor(data);
+                               FREE_ZVAL(data);
+                               return 0;
                }
                
                zval_dtor(key);