[TD-2534]<fix>: fix crash on null pointer parser

This commit is contained in:
Minglei Jin 2020-12-23 13:24:25 +08:00
parent a0981ed73e
commit dbb4086236
1 changed files with 1 additions and 1 deletions

View File

@ -136,7 +136,7 @@ void httpSendErrorResp(HttpContext *pContext, int32_t errNo) {
else
httpCode = 400;
if (pContext->parser->httpCode != 0) {
if (pContext->parser && pContext->parser->httpCode != 0) {
httpCode = pContext->parser->httpCode;
}