aboutsummaryrefslogtreecommitdiffstats
path: root/os/rt/src/chcond.c
diff options
context:
space:
mode:
Diffstat (limited to 'os/rt/src/chcond.c')
-rw-r--r--os/rt/src/chcond.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/os/rt/src/chcond.c b/os/rt/src/chcond.c
index b6d6219da..20b0cd47e 100644
--- a/os/rt/src/chcond.c
+++ b/os/rt/src/chcond.c
@@ -154,7 +154,7 @@ void chCondBroadcastI(condition_variable_t *cp) {
/* Empties the condition variable queue and inserts all the threads into the
ready list in FIFO order. The wakeup message is set to @p MSG_RESET in
order to make a chCondBroadcast() detectable from a chCondSignal().*/
- while (cp->c_queue.p_next != (void *)&cp->c_queue) {
+ while (queue_notempty(&cp->c_queue)) {
chSchReadyI(queue_fifo_remove(&cp->c_queue))->p_u.rdymsg = MSG_RESET;
}
}