X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=http_request_object.c;h=11a623030077bb658649f77f262f203bc07702a1;hb=caef0e9b14e6c7fcaa50685a5a3eb46dc1df65ec;hp=bc7a0f854e1107fd361fd67fd7f501ca8bd14aa3;hpb=5b8614c1c854c6683af7bf2dca4a6c970d4bfc25;p=m6w6%2Fext-http diff --git a/http_request_object.c b/http_request_object.c index bc7a0f8..11a6230 100644 --- a/http_request_object.c +++ b/http_request_object.c @@ -633,7 +633,7 @@ STATUS _http_request_object_responsehandler(http_request_object *obj, zval *this } UPD_PROP(long, responseCode, msg->http.info.response.code); - UPD_PROP(string, responseStatus, msg->http.info.response.status); + UPD_PROP(string, responseStatus, msg->http.info.response.status ? msg->http.info.response.status : ""); MAKE_STD_ZVAL(resp); array_init(resp); @@ -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);