fix double free

This commit is contained in:
yihaoDeng 2024-10-29 20:23:28 +08:00
parent d4b0550a01
commit f0ec573611
1 changed files with 0 additions and 4 deletions

View File

@ -1307,8 +1307,6 @@ static void cliBatchSendCb(uv_write_t* req, int status) {
SCliReq* pReq = QUEUE_DATA(h, SCliReq, q); SCliReq* pReq = QUEUE_DATA(h, SCliReq, q);
transQueuePush(&conn->reqsSentOut, &pReq->q); transQueuePush(&conn->reqsSentOut, &pReq->q);
} }
QUEUE_INIT(&wrapper->node);
freeWReqToWQ(&conn->wq, wrapper); freeWReqToWQ(&conn->wq, wrapper);
int32_t ref = transUnrefCliHandle(conn); int32_t ref = transUnrefCliHandle(conn);
@ -1501,8 +1499,6 @@ int32_t cliBatchSend(SCliConn* pConn, int8_t direct) {
SCliReq* pReq = QUEUE_DATA(h, SCliReq, q); SCliReq* pReq = QUEUE_DATA(h, SCliReq, q);
transQueuePush(&pConn->reqsToSend, &pReq->q); transQueuePush(&pConn->reqsToSend, &pReq->q);
} }
QUEUE_INIT(&pWreq->node);
freeWReqToWQ(&pConn->wq, req->data); freeWReqToWQ(&pConn->wq, req->data);
code = TSDB_CODE_THIRDPARTY_ERROR; code = TSDB_CODE_THIRDPARTY_ERROR;
TAOS_UNUSED(transUnrefCliHandle(pConn)); TAOS_UNUSED(transUnrefCliHandle(pConn));