From: foobar Date: Tue, 17 Feb 2004 22:04:05 +0000 (+0000) Subject: MFB: - Fix bug #26753 (zend_fetch_list_dtor_id() does not check NULL strings) X-Git-Tag: RELEASE_0_2_0~284 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=2b8611ae3bd8f2377ce29670beaaeac7b6b4a298;p=php MFB: - Fix bug #26753 (zend_fetch_list_dtor_id() does not check NULL strings) --- diff --git a/Zend/zend_list.c b/Zend/zend_list.c index c8676a2473..bd88e44c76 100644 --- a/Zend/zend_list.c +++ b/Zend/zend_list.c @@ -315,7 +315,7 @@ ZEND_API int zend_fetch_list_dtor_id(char *type_name) zend_hash_internal_pointer_reset_ex(&list_destructors, &pos); while (zend_hash_get_current_data_ex(&list_destructors, (void **)&lde, &pos) == SUCCESS) { - if (strcmp(type_name, lde->type_name) == 0) { + if (lde->type_name && (strcmp(type_name, lde->type_name) == 0)) { #if 0 printf("Found resource id %d for resource type %s\n", (*lde).resource_id, type_name); #endif