- rather show the exception than a useless "Cannot call HttpRequest::onfinish()"
authorMichael Wallner <mike@php.net>
Tue, 18 Apr 2006 15:02:58 +0000 (15:02 +0000)
committerMichael Wallner <mike@php.net>
Tue, 18 Apr 2006 15:02:58 +0000 (15:02 +0000)
http_request_object.c

index 1d04ed119e39a4248cd8fcd28f6e2fb64a9c899c..11a623030077bb658649f77f262f203bc07702a1 100644 (file)
@@ -688,7 +688,7 @@ STATUS _http_request_object_responsehandler(http_request_object *obj, zval *this
                ret = FAILURE;
        }
        
-       if (zend_hash_exists(&Z_OBJCE_P(getThis())->function_table, "onfinish", sizeof("onfinish"))) {
+       if (!EG(exception) && zend_hash_exists(&Z_OBJCE_P(getThis())->function_table, "onfinish", sizeof("onfinish"))) {
                zval *param;
                
                MAKE_STD_ZVAL(param);