X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=http_message_object.c;h=c984e960fa00a34e2da1a78f282c55784d1e8443;hb=2c0c193bdcfaa2e3c6b336da078f371e96fcec52;hp=edc18a0499d549d1a7c026afd1e25c51e36aef2c;hpb=5ecd200ee2e3d887f0393948aec1914867e64293;p=m6w6%2Fext-http diff --git a/http_message_object.c b/http_message_object.c index edc18a0..c984e96 100644 --- a/http_message_object.c +++ b/http_message_object.c @@ -637,13 +637,13 @@ static HashTable *_http_message_object_get_props(zval *object TSRMLS_DC) case HTTP_MSG_REQUEST: ASSOC_PROP(array, long, "responseCode", 0); ASSOC_STRINGL(array, "responseStatus", "", 0); - ASSOC_STRING(array, "requestMethod", msg->http.info.request.method); - ASSOC_STRING(array, "requestUrl", msg->http.info.request.url); + ASSOC_STRING(array, "requestMethod", msg->http.info.request.method?msg->http.info.request.method:""); + ASSOC_STRING(array, "requestUrl", msg->http.info.request.url?msg->http.info.request.url:""); break; case HTTP_MSG_RESPONSE: ASSOC_PROP(array, long, "responseCode", msg->http.info.response.code); - ASSOC_STRING(array, "responseStatus", msg->http.info.response.status); + ASSOC_STRING(array, "responseStatus", msg->http.info.response.status?msg->http.info.response.status:""); ASSOC_STRINGL(array, "requestMethod", "", 0); ASSOC_STRINGL(array, "requestUrl", "", 0); break;