modify signal with broadcast for support multithread

Signed-off-by: caochao <caochao@huawei.com>
Change-Id: Ifd4bb849035576d9a1b8499f7e00ed6b2b2c9278
This commit is contained in:
caochao
2022-02-23 15:29:38 +08:00
parent 49ba634999
commit cf949ccbc3
+1 -1
View File
@@ -53,7 +53,7 @@ int QUEUE_Put(MQueueId queueId, const void *element, uint8 pri, int timeout)
int ret = LFQUE_Push(queue->queue, element, pri);
pthread_mutex_unlock(&queue->wMutex);
pthread_mutex_lock(&queue->rMutex);
pthread_cond_signal(&queue->cond);
pthread_cond_broadcast(&queue->cond);
pthread_mutex_unlock(&queue->rMutex);
return ret;
}