cederom commented on code in PR #3150:
URL: https://github.com/apache/nuttx-apps/pull/3150#discussion_r2249325162


##########
nshlib/nsh_proccmds.c:
##########
@@ -257,6 +260,28 @@ static void nsh_parse_statusline(FAR char *line,
     }
 #endif
 }
+
+static void nsh_parse_gstatusline(FAR char *line,
+                                  FAR struct nsh_taskstatus_s *status)
+{
+  /* Parse the group status.
+   *
+   *   Format:
+   *
+   *            111111111122222222223
+   *   123456789012345678901234567890
+   *   Main task:  nnnnn              PID
+   *   Parent:     nnnnn              Parent PID
+   *   Flags:      0x**               Group flags, See GROUP_FLAG_*
+   *   Members:    nnnn...            Count of members
+   *   Member IDs: nnnnn,nnnnn,...    List of members{PID0, PID1, ...)
+   */
+
+  if (strncmp(line, g_ppid, strlen(g_ppid)) == 0)
+    {
+      status->td_ppid = atoi(&line[12]);

Review Comment:
   It is always present? No option we may derefecence NULL pointer here? :-)



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