diff options
Diffstat (limited to 'os/kernel/src')
| -rw-r--r-- | os/kernel/src/chthreads.c | 2 | 
1 files changed, 2 insertions, 0 deletions
| diff --git a/os/kernel/src/chthreads.c b/os/kernel/src/chthreads.c index f96cea942..6f67f7093 100644 --- a/os/kernel/src/chthreads.c +++ b/os/kernel/src/chthreads.c @@ -427,7 +427,9 @@ msg_t chThdWait(Thread *tp) {    chSysLock();    chDbgAssert(tp != currp, "chThdWait(), #1", "waiting self"); +#if CH_USE_DYNAMIC    chDbgAssert(tp->p_refs > 0, "chThdWait(), #2", "not referenced"); +#endif    if (tp->p_state != THD_STATE_FINAL) {      list_insert(currp, &tp->p_waiting);      chSchGoSleepS(THD_STATE_WTEXIT); | 
