From: Dmitry Stogov Date: Thu, 12 Feb 2004 16:41:58 +0000 (+0000) Subject: fix: possible crash was fixed X-Git-Tag: RELEASE_0_2_0~364 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=69eb0041b18a4b8bca0574cafeaa0e24c44b4f8f;p=php fix: possible crash was fixed --- diff --git a/ext/soap/soap.c b/ext/soap/soap.c index 6826c6a733..29cc3e6437 100644 --- a/ext/soap/soap.c +++ b/ext/soap/soap.c @@ -3190,7 +3190,7 @@ static void function_to_string(sdlFunctionPtr function, smart_str *buf) if (function->responseParameters && function->responseParameters->pListHead) { sdlParamPtr *param; param = function->responseParameters->pListHead->pData; - if ((*param)->encode->details.type_str) { + if ((*param)->encode && (*param)->encode->details.type_str) { smart_str_appendl(buf, (*param)->encode->details.type_str, strlen((*param)->encode->details.type_str)); smart_str_appendc(buf, ' '); } else { @@ -3209,7 +3209,7 @@ static void function_to_string(sdlFunctionPtr function, smart_str *buf) i = 0; zend_hash_internal_pointer_reset_ex(function->requestParameters, &pos); while (zend_hash_get_current_data_ex(function->requestParameters, (void **)¶m, &pos) != FAILURE) { - if ((*param)->encode->details.type_str) { + if ((*param)->encode && (*param)->encode->details.type_str) { smart_str_appendl(buf, (*param)->encode->details.type_str, strlen((*param)->encode->details.type_str)); } else { smart_str_appendl(buf, "mixed ", 6);