This is an automated email from the ASF dual-hosted git repository.

acassis pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nuttx-apps.git

commit 418cf21224309faa838c77abd87285c977caf20a
Author: Matteo Golin <[email protected]>
AuthorDate: Wed May 27 19:56:44 2026 -0400

    apps/nxinit: Fix uninitialized variable
    
    Without debug enabled, the code would not compile due to checking
    `WIFEXITED(wstatus)` when `wstatus` was uninitialized.
    
    Signed-off-by: Matteo Golin <[email protected]>
---
 system/nxinit/init.c | 8 +-------
 1 file changed, 1 insertion(+), 7 deletions(-)

diff --git a/system/nxinit/init.c b/system/nxinit/init.c
index d501abcad..1a542f796 100644
--- a/system/nxinit/init.c
+++ b/system/nxinit/init.c
@@ -80,13 +80,7 @@ static void reap_process(FAR struct service_manager_s *sm,
 
   for (; ; )
     {
-      pid = waitpid(-1,
-#ifdef CONFIG_SYSTEM_NXINIT_DEBUG
-                    &wstatus,
-#else
-                    NULL,
-#endif
-                    WNOHANG);
+      pid = waitpid(-1, &wstatus, WNOHANG);
       if (pid <= 0)
         {
           break;

Reply via email to