From 5b54322dc7c76e2d4b391cec81e53b4a27da8189 Mon Sep 17 00:00:00 2001 From: Marcus Boerger Date: Wed, 2 Jul 2003 23:58:47 +0000 Subject: Temporairy solution to overcome shutdown propbelms with objects that have hidden destructors. # # If we set the error level to E_ERROR what we must to to be correct and an # object needs to be automatically destructed in shutdown process then the # exit would cause memory corruption and a SEGV. --- Zend/zend_objects.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Zend/zend_objects.c') diff --git a/Zend/zend_objects.c b/Zend/zend_objects.c index d1074dd237..1d3685e84d 100644 --- a/Zend/zend_objects.c +++ b/Zend/zend_objects.c @@ -47,7 +47,8 @@ ZEND_API void zend_objects_destroy_object(zend_object *object, zend_object_handl */ if (object->ce != EG(scope)) { zend_nuke_object(object TSRMLS_CC); /* unfortunately we *must* destroy it now anyway */ - zend_error(E_ERROR, "Call to private destructor from context '%s'", EG(scope) ? EG(scope)->name : ""); + /* this is a E_ERROR in real but we can't do that right now because of problems in shutdown */ + zend_error(E_WARNING, "Call to private destructor from context '%s'", EG(scope) ? EG(scope)->name : ""); return; } } else { @@ -55,7 +56,7 @@ ZEND_API void zend_objects_destroy_object(zend_object *object, zend_object_handl */ if (!zend_check_protected(destructor->common.scope, EG(scope))) { zend_nuke_object(object TSRMLS_CC); /* unfortunately we *must* destroy it now anyway */ - zend_error(E_ERROR, "Call to protected destructor from context '%s'", EG(scope) ? EG(scope)->name : ""); + zend_error(E_WARNING, "Call to protected destructor from context '%s'", EG(scope) ? EG(scope)->name : ""); return; } } -- cgit v1.2.1