You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2020/12/11 13:15:30 UTC

[GitHub] [incubator-nuttx] patacongo commented on a change in pull request #2518: sched: Implement getpid and gettid correctly

patacongo commented on a change in pull request #2518:
URL: https://github.com/apache/incubator-nuttx/pull/2518#discussion_r540937984



##########
File path: sched/task/task_getpid.c
##########
@@ -95,11 +95,17 @@ pid_t getpid(void)
 
       if (rtcb->task_state == TSTATE_TASK_RUNNING)
         {
+#if !defined(CONFIG_DISABLE_PTHREAD) && defined(CONFIG_SCHED_HAVE_PARENT)
+          /* Yes.. Return the task ID from the main TCB */

Review comment:
       I think that this change should apply even if CONFIG_SCHED_HAVE_PARENT is not defined, should it not?




----------------------------------------------------------------
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:
users@infra.apache.org