diff --git a/source/libs/transport/src/thttp.c b/source/libs/transport/src/thttp.c index b0a384cfcc..63f07d7493 100644 --- a/source/libs/transport/src/thttp.c +++ b/source/libs/transport/src/thttp.c @@ -293,7 +293,7 @@ int32_t httpSendQuit() { static int32_t taosSendHttpReportImpl(const char* server, const char* uri, uint16_t port, char* pCont, int32_t contLen, EHttpCompFlag flag) { - if (contLen == 0) { + if (pCont == NULL || contLen == 0) { tError("http-report failed to report empty packet"); return -1; }