hujun260 commented on code in PR #18118:
URL: https://github.com/apache/nuttx/pull/18118#discussion_r2719537656
##########
sched/sched/sched_get_stackinfo.c:
##########
@@ -61,7 +61,12 @@ int nxsched_get_stackinfo(pid_t pid, FAR struct stackinfo_s
*stackinfo)
FAR struct tcb_s *rtcb = this_task(); /* TCB of running task */
FAR struct tcb_s *qtcb; /* TCB of queried task */
- DEBUGASSERT(rtcb != NULL && stackinfo != NULL);
+ DEBUGASSERT(stackinfo != NULL);
+
+ if (rtcb == NULL)
+ {
+ return -ESRCH;
Review Comment:
done
--
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]