mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-19 01:53:34 +08:00
Cosmetic cleanup from SIGCHLD changes
git-svn-id: http://svn.code.sf.net/p/nuttx/code/trunk@5514 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
@@ -115,9 +115,12 @@ int task_deletecurrent(void)
|
||||
* does not correspond to the thread that is running. Disabling pre-
|
||||
* emption on this TCB and marking the new ready-to-run task as not
|
||||
* running (see, for example, get_errno_ptr()).
|
||||
*
|
||||
* We disable pre-emption here by directly incrementing the lockcount
|
||||
* (vs. calling sched_lock()).
|
||||
*/
|
||||
|
||||
sched_lock();
|
||||
rtcb->lockcount++;
|
||||
rtcb->task_state = TSTATE_TASK_READYTORUN;
|
||||
|
||||
/* Move the TCB to the specified blocked task list and delete it */
|
||||
@@ -143,7 +146,6 @@ int task_deletecurrent(void)
|
||||
* the lockcount on rctb.
|
||||
*/
|
||||
|
||||
DEBUGASSERT(rtcb->lockcount > 0);
|
||||
rtcb->lockcount--;
|
||||
return OK;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user