stmt2/close: wait only when !semWaited (i.e. execed current batch)
This commit is contained in:
parent
e7cfe21e72
commit
aecab6e2ca
|
@ -1701,7 +1701,7 @@ int stmtClose2(TAOS_STMT2* stmt) {
|
||||||
pStmt->bindThreadInUse = false;
|
pStmt->bindThreadInUse = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pStmt->options.asyncExecFn) {
|
if (pStmt->options.asyncExecFn && !pStmt->semWaited) {
|
||||||
(void)tsem_wait(&pStmt->asyncQuerySem);
|
(void)tsem_wait(&pStmt->asyncQuerySem);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue