fix TBASE-1176

This commit is contained in:
localvar 2019-11-18 06:29:11 +00:00
parent 6240637a39
commit d458545cce
1 changed files with 3 additions and 1 deletions

View File

@ -549,7 +549,9 @@ void* taosTmrInit(int maxNumOfTmrs, int resolution, int longest, const char* lab
void taosTmrCleanUp(void* handle) {
tmr_ctrl_t* ctrl = (tmr_ctrl_t*)handle;
assert(ctrl != NULL && ctrl->label[0] != 0);
if (ctrl == NULL || ctrl->label[0] == 0) {
return;
}
tmrTrace("%s timer controller is cleaned up.", ctrl->label);
ctrl->label[0] = 0;