Skip to content

Commit

Permalink
sched: add some DEBUGASSERT when nxsched_release_tcb()
Browse files Browse the repository at this point in the history
RTOSXMDPYX-2765

Change-Id: I02051657b04f5ccb5845aaed33ead37d21052394
Signed-off-by: ligd <[email protected]>
  • Loading branch information
GUIDINGLI authored and xiaoxiang781216 committed Nov 16, 2024
1 parent 2cced03 commit c67db8e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sched/sched/sched_releasetcb.c
Original file line number Diff line number Diff line change
Expand Up @@ -107,6 +107,10 @@ int nxsched_release_tcb(FAR struct tcb_s *tcb, uint8_t ttype)

if (tcb)
{
/* Released tcb shouldn't on any list */

DEBUGASSERT(tcb->flink == NULL && tcb->blink == NULL);

#ifndef CONFIG_DISABLE_POSIX_TIMERS
/* Release any timers that the task might hold. We do this
* before release the PID because it may still be trying to
Expand Down

0 comments on commit c67db8e

Please sign in to comment.