btashton commented on a change in pull request #2737: URL: https://github.com/apache/incubator-nuttx/pull/2737#discussion_r563440031
########## File path: sched/task/task_setup.c ########## @@ -121,17 +122,18 @@ static int nxtask_assign_pid(FAR struct tcb_s *tcb) #endif tcb->pid = next_pid; - sched_unlock(); - return OK; + ret = OK; + goto errout; } } +errout: /* If we get here, then the g_pidhash[] table is completely full. Review comment: This comment is not correct any more since this is now _the_ return path. Also maybe the label name should change. ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org