From ecfe407f32f01426ab7d9fff5f31aacb11c2edd5 Mon Sep 17 00:00:00 2001 From: yihaoDeng Date: Fri, 11 Oct 2024 14:38:29 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/3.0' into enh/opt-transport --- source/libs/transport/src/transCli.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/libs/transport/src/transCli.c b/source/libs/transport/src/transCli.c index 4426eb0d44..ee7fe3e105 100644 --- a/source/libs/transport/src/transCli.c +++ b/source/libs/transport/src/transCli.c @@ -3866,10 +3866,10 @@ int32_t transHeapDelete(SHeap* heap, SCliConn* p) { } int32_t transHeapBalance(SHeap* heap, SCliConn* p) { - if (p->inHeap == 0) { + if (p->inHeap == 0 && heap == NULL || heap->heap == NULL) { return 0; } - if (heap && heap->heap && heap->heap->nelts >= 64) { + if (heap->heap->nelts >= 64) { tDebug("conn %p heap busy,heap size:%d", heap->heap->nelts); } heapRemove(heap->heap, &p->node);