Merge pull request #29565 from taosdata/fix/main/TD-33523
fix[TD-33523]async problem in unit test
This commit is contained in:
commit
6f7533f4d0
|
@ -197,7 +197,7 @@ void do_stmt(TAOS* taos, TAOS_STMT2_OPTION* option, const char* sql, int CTB_NUM
|
||||||
checkError(stmt, code);
|
checkError(stmt, code);
|
||||||
|
|
||||||
// exec
|
// exec
|
||||||
int affected;
|
int affected = 0;
|
||||||
code = taos_stmt2_exec(stmt, &affected);
|
code = taos_stmt2_exec(stmt, &affected);
|
||||||
total_affected += affected;
|
total_affected += affected;
|
||||||
checkError(stmt, code);
|
checkError(stmt, code);
|
||||||
|
@ -219,8 +219,9 @@ void do_stmt(TAOS* taos, TAOS_STMT2_OPTION* option, const char* sql, int CTB_NUM
|
||||||
taosMemoryFree(tags);
|
taosMemoryFree(tags);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (option->asyncExecFn == NULL) {
|
||||||
ASSERT_EQ(total_affected, CYC_NUMS * ROW_NUMS * CTB_NUMS);
|
ASSERT_EQ(total_affected, CYC_NUMS * ROW_NUMS * CTB_NUMS);
|
||||||
|
}
|
||||||
for (int i = 0; i < CTB_NUMS; i++) {
|
for (int i = 0; i < CTB_NUMS; i++) {
|
||||||
taosMemoryFree(tbs[i]);
|
taosMemoryFree(tbs[i]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue