diff options
author | Sebastian Bergmann <sebastian@php.net> | 2002-04-19 16:53:36 +0000 |
---|---|---|
committer | Sebastian Bergmann <sebastian@php.net> | 2002-04-19 16:53:36 +0000 |
commit | bf5bb8427734100e897e64ec21f1a6ee31a15219 (patch) | |
tree | 8799598f820b1e0996404a21b38683b3d4bb2738 /Zend/zend_list.c | |
parent | 2697ce689d5362ab58fb914a16ee501917f9e18b (diff) | |
download | php-git-bf5bb8427734100e897e64ec21f1a6ee31a15219.tar.gz |
MFZE1: make sure the resource-list is always consistent during shutdown (Thies).
Diffstat (limited to 'Zend/zend_list.c')
-rw-r--r-- | Zend/zend_list.c | 25 |
1 files changed, 1 insertions, 24 deletions
diff --git a/Zend/zend_list.c b/Zend/zend_list.c index 4f33c8c344..0bae054bab 100644 --- a/Zend/zend_list.c +++ b/Zend/zend_list.c @@ -230,30 +230,7 @@ int zend_init_rsrc_plist(TSRMLS_D) void zend_destroy_rsrc_list(HashTable *ht TSRMLS_DC) { - Bucket *p, *q; - - while (1) { - p = ht->pListTail; - if (!p) { - break; - } - q = p->pListLast; - if (q) { - q->pListNext = NULL; - } - ht->pListTail = q; - - if (ht->pDestructor) { - zend_try { - ht->pDestructor(p->pData); - } zend_end_try(); - } - if (!p->pDataPtr && p->pData) { - pefree(p->pData, ht->persistent); - } - pefree(p, ht->persistent); - } - pefree(ht->arBuckets, ht->persistent); + zend_hash_graceful_reverse_destroy(ht); } |