patacongo commented on issue #4612:
URL: 
https://github.com/apache/incubator-nuttx/issues/4612#issuecomment-927339156


   Here is a test case:
   
   ```
   static void *thread_func(FAR void *parameter)
   {
     /* Wait a bit then call exit */
   
     printf("Child: Started\n");
     sleep(1);
   
     printf("Child: exit()\n");
     exit(0);
   }
   
   int main(int argc, FAR char *argv[])
   {
     pthread_t thread;
     int status;
   
     /* Start the thread instances */
   
     printf("main: Starting thread\n");
     status = pthread_create(&thread, NULL, thread_func, (pthread_addr_t)NULL);
     if (status != 0)
       {
         printf("ERROR in thread creation: %d\n", status);
       }
   
     /* And exit the main thread */
   
     printf("main: pthread_exit()\n");
     pthread_exit(NULL);
   }
   
   ```
   When I run this test, I get:
   
   ```
   nsh> exit
   main: Starting thread
   Child: Started
   main: pthread_exit()
   nsh> Child: exit()
   
   nsh>
   ```
   
   So I conclude that there is no problem.  Sorry for the false alarm.  I will 
close this issue now.


-- 
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.

To unsubscribe, e-mail: commits-unsubscr...@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to