diff --git a/source/libs/stream/src/streamExec.c b/source/libs/stream/src/streamExec.c index dbceb83803..2302e00bb3 100644 --- a/source/libs/stream/src/streamExec.c +++ b/source/libs/stream/src/streamExec.c @@ -621,7 +621,7 @@ int32_t streamTryExec(SStreamTask* pTask) { } taosThreadMutexLock(&pTask->lock); - if (taosQueueEmpty(pTask->inputInfo.queue->pQueue) || streamTaskShouldStop(&pTask->status) || + if ((streamQueueGetNumOfItems(pTask->inputInfo.queue) > 0) || streamTaskShouldStop(&pTask->status) || streamTaskShouldPause(&pTask->status)) { atomic_store_8(&pTask->status.schedStatus, TASK_SCHED_STATUS__INACTIVE); taosThreadMutexUnlock(&pTask->lock);