From: Michael Wallner Date: Mon, 13 Jun 2005 16:48:05 +0000 (+0000) Subject: - fix memleak X-Git-Tag: RELEASE_0_9_0~26 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=84587a7d0dba04eb79c40806708ec3aa28d89ed6;p=m6w6%2Fext-http - fix memleak --- diff --git a/http_request_object.c b/http_request_object.c index 2f51ec2..bc2cfa0 100644 --- a/http_request_object.c +++ b/http_request_object.c @@ -301,7 +301,7 @@ STATUS _http_request_object_responsehandler(http_request_object *obj, zval *this if (msg = http_message_parse(PHPSTR_VAL(&obj->response), PHPSTR_LEN(&obj->response))) { char *body; size_t body_len; - zval *headers, *message, *resp = GET_PROP(obj, responseData), *info = GET_PROP(obj, responseInfo); + zval *headers, *message = GET_PROP(obj, responseMessage), *resp = GET_PROP(obj, responseData), *info = GET_PROP(obj, responseInfo); UPD_PROP(obj, long, responseCode, msg->info.response.code); @@ -314,7 +314,6 @@ STATUS _http_request_object_responsehandler(http_request_object *obj, zval *this add_assoc_zval(resp, "headers", headers); add_assoc_stringl(resp, "body", body, body_len, 0); - MAKE_STD_ZVAL(message); Z_TYPE_P(message) = IS_OBJECT; message->value.obj = http_message_object_from_msg(msg); SET_PROP(obj, responseMessage, message);