You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2022/08/15 10:54:55 UTC

[GitHub] [incubator-nuttx-apps] zhhyu7 commented on a diff in pull request #1269: Some WAPI changes

zhhyu7 commented on code in PR #1269:
URL: https://github.com/apache/incubator-nuttx-apps/pull/1269#discussion_r945614868


##########
wireless/wapi/src/wireless.c:
##########
@@ -1256,14 +1256,14 @@ int wapi_scan_stat(int sock, FAR const char *ifname)
           return 1;
         }
 
-      printf("err[%d]: %s\n", errno, strerror(errno));
-    }
-  else

Review Comment:
   > it's wrong?
   
   change printf(error) to WAPI_IOCTL_STRERROR, and correct return value when ioctl return >=0.
   Otherwise, when multiple threads switch, errno will be set to someone else's system call return code.



-- 
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-unsubscribe@nuttx.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org