- fix crash if there's no response status string after the response code
authorMichael Wallner <mike@php.net>
Wed, 12 Apr 2006 08:39:23 +0000 (08:39 +0000)
committerMichael Wallner <mike@php.net>
Wed, 12 Apr 2006 08:39:23 +0000 (08:39 +0000)
http_request_object.c

index bc7a0f854e1107fd361fd67fd7f501ca8bd14aa3..1d04ed119e39a4248cd8fcd28f6e2fb64a9c899c 100644 (file)
@@ -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);