diff --git a/include/common/tmsg.h b/include/common/tmsg.h index ac6ce82ffb..c4a4e92648 100644 --- a/include/common/tmsg.h +++ b/include/common/tmsg.h @@ -2337,6 +2337,7 @@ int32_t tSerializeSClientHbBatchReq(void* buf, int32_t bufLen, const SClientHbBa int32_t tDeserializeSClientHbBatchReq(void* buf, int32_t bufLen, SClientHbBatchReq* pReq); static FORCE_INLINE void tFreeClientHbBatchReq(void* pReq) { + if (pReq == NULL) return; SClientHbBatchReq* req = (SClientHbBatchReq*)pReq; taosArrayDestroyEx(req->reqs, tFreeClientHbReq); taosMemoryFree(pReq);