fix:[TD-33600] windows error if taos exist without connection

This commit is contained in:
wangmm0220 2025-01-23 14:55:24 +08:00
parent 931f4e354f
commit b8a5bcfbf9
1 changed files with 5 additions and 4 deletions

View File

@ -1601,6 +1601,11 @@ void tmqFreeImpl(void* handle) {
static void tmqMgmtInit(void) {
tmqInitRes = 0;
if (taosThreadMutexInit(&tmqMgmt.lock, NULL) != 0){
goto END;
}
tmqMgmt.timer = taosTmrInit(1000, 100, 360000, "TMQ");
if (tmqMgmt.timer == NULL) {
@ -1612,10 +1617,6 @@ static void tmqMgmtInit(void) {
goto END;
}
if (taosThreadMutexInit(&tmqMgmt.lock, NULL) != 0){
goto END;
}
return;
END:
tmqInitRes = terrno;