xiaoxiang781216 commented on code in PR #10380:
URL: https://github.com/apache/nuttx/pull/10380#discussion_r1306591058


##########
binfmt/binfmt_execmodule.c:
##########
@@ -292,6 +368,11 @@ int exec_module(FAR struct binary_s *binp,
     }
 #endif
 
+  if (exec_inner)
+    {
+      exchange_pid(this_task(), (FAR struct tcb_s *)tcb);

Review Comment:
   let's call task_reparent in exchange_pid



##########
binfmt/binfmt_exec.c:
##########
@@ -74,7 +75,7 @@
 int exec_spawn(FAR const char *filename, FAR char * const *argv,
                FAR char * const *envp, FAR const struct symtab_s *exports,
                int nexports, FAR const posix_spawn_file_actions_t *actions,
-               FAR const posix_spawnattr_t *attr)
+               FAR const posix_spawnattr_t *attr, int exec_inner)

Review Comment:
   let's add an internal function to avoid change exec_spawn prototype



##########
include/nuttx/binfmt/binfmt.h:
##########
@@ -272,7 +272,8 @@ int unload_module(FAR struct binary_s *bin);
 int exec_module(FAR struct binary_s *binp,
                 FAR const char *filename, FAR char * const *argv,
                 FAR char * const *envp,
-                FAR const posix_spawn_file_actions_t *actions);
+                FAR const posix_spawn_file_actions_t *actions,
+                int exec_inner);

Review Comment:
   ```suggestion
                   bool spawn);
   ```



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to