zs39 commented on code in PR #17520:
URL: https://github.com/apache/nuttx/pull/17520#discussion_r2703651926


##########
net/pkt/pkt_recvmsg.c:
##########
@@ -474,7 +474,7 @@ ssize_t pkt_recvmsg(FAR struct socket *psock, FAR struct 
msghdr *msg,
   if (psock->s_type != SOCK_RAW)
     {
       nerr("ERROR: Unsupported socket type: %d\n", psock->s_type);
-      ret = -ENOSYS;
+      return -ENOSYS;

Review Comment:
   The PR description has been modified. As described above, psock normally 
only supports two types; if it's not one of these two types, an error will 
occur during creation. Therefore, this branch shouldn't be reached under normal 
circumstances. Since interception is performed during creation, no additional 
descriptive information should be needed here.
   
https://github.com/apache/nuttx/blob/18820ef07d3b9b901aa3e5d1459c311f605f3ca7/net/pkt/pkt_sockif.c#L162



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