From bb0c337e43e03fa75facba948bc48e13102d2ab0 Mon Sep 17 00:00:00 2001 From: dapan1121 Date: Fri, 9 Dec 2022 10:06:07 +0800 Subject: [PATCH] fix: client retry issue --- source/client/src/clientMain.c | 2 ++ source/libs/parser/src/parInsertSql.c | 4 ---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/source/client/src/clientMain.c b/source/client/src/clientMain.c index 29887115b9..329d715aaf 100644 --- a/source/client/src/clientMain.c +++ b/source/client/src/clientMain.c @@ -936,6 +936,8 @@ void doAsyncQuery(SRequestObj *pRequest, bool updateMetaForce) { tscError("0x%" PRIx64 " error happens, code:%d - %s, reqId:0x%" PRIx64, pRequest->self, code, tstrerror(code), pRequest->requestId); destorySqlCallbackWrapper(pWrapper); + qDestroyQuery(pRequest->pQuery); + pRequest->pQuery = NULL; if (NEED_CLIENT_HANDLE_ERROR(code)) { tscDebug("0x%" PRIx64 " client retry to handle the error, code:%d - %s, tryCount:%d, reqId:0x%" PRIx64, diff --git a/source/libs/parser/src/parInsertSql.c b/source/libs/parser/src/parInsertSql.c index ff0621c09e..36420599b3 100644 --- a/source/libs/parser/src/parInsertSql.c +++ b/source/libs/parser/src/parInsertSql.c @@ -1782,10 +1782,6 @@ static int32_t setVnodeModifOpStmt(SInsertParseContext* pCxt, SCatalogReq* pCata SVnodeModifOpStmt* pStmt) { clearCatalogReq(pCatalogReq); - if (NULL == pMetaData) { - return TSDB_CODE_SUCCESS; - } - if (pStmt->usingTableProcessing) { return getTableSchemaFromMetaData(pCxt, pMetaData, pStmt, true); }