pkarashchenko commented on code in PR #1649:
URL: https://github.com/apache/nuttx-apps/pull/1649#discussion_r1136233168


##########
system/nxlooper/nxlooper.c:
##########
@@ -24,21 +24,21 @@
 
 #include <nuttx/config.h>
 
-#include <sys/param.h>
-#include <sys/types.h>
-#include <sys/ioctl.h>
-
-#include <stdint.h>
+#include <assert.h>
+#include <debug.h>
+#include <dirent.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <sched.h>
 #include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
+#include <stdlib.h>
 #include <string.h>

Review Comment:
   I think that strings.h includes string.h, so there is no need to include both



##########
interpreters/luamodules/cjson/0002-bugfix-Fix-implicit-declaration-warning-for-strncase.patch:
##########
@@ -0,0 +1,26 @@
+From e6e8fbe68a95bf6fca463781dbc22e631c4b7b7a Mon Sep 17 00:00:00 2001
+From: Gustavo Henrique Nihei <gustavo.ni...@espressif.com>
+Date: Wed, 8 Mar 2023 17:18:02 -0300
+Subject: [PATCH] bugfix: Fix implicit declaration warning for strncasecmp
+ function
+
+Signed-off-by: Gustavo Henrique Nihei <gustavo.ni...@espressif.com>
+---
+ lua_cjson.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/lua_cjson.c b/lua_cjson.c
+index 42672de..f443626 100644
+--- a/lua_cjson.c
++++ b/lua_cjson.c
+@@ -39,6 +39,7 @@
+ #include <assert.h>
+ #include <stdint.h>
+ #include <string.h>
++#include <strings.h>

Review Comment:
   ```suggestion
   -#include <string.h>
   +#include <strings.h>
   ```
   



##########
system/nxplayer/nxplayer.c:
##########
@@ -24,30 +24,29 @@
 
 #include <nuttx/config.h>
 
+#include <assert.h>
+#include <debug.h>
+#include <dirent.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <netutils/netlib.h>

Review Comment:
   Maybe this can be moved to the bottom and grouped out of standard includes?



##########
system/nxrecorder/nxrecorder.c:
##########
@@ -24,23 +24,24 @@
 
 #include <nuttx/config.h>
 
-#include <sys/types.h>
-#include <sys/ioctl.h>
-
-#include <stdint.h>
+#include <assert.h>
+#include <debug.h>
+#include <dirent.h>
+#include <errno.h>
+#include <fcntl.h>
+#include <sched.h>
 #include <stdbool.h>
+#include <stdint.h>
 #include <stdio.h>
+#include <stdlib.h>
 #include <string.h>
 #include <strings.h>
-#include <stdlib.h>
-#include <fcntl.h>
-#include <assert.h>
-#include <errno.h>
-#include <dirent.h>
-#include <debug.h>
+#include <sys/types.h>
+#include <sys/ioctl.h>

Review Comment:
   Maybe it can be put after unistd.h?
   What was the reason for moving it here?



##########
system/nxplayer/nxplayer_mp3.c:
##########
@@ -22,12 +22,14 @@
  * Included Files
  ****************************************************************************/
 
-#include <sys/types.h>
+#include <nuttx/config.h>

Review Comment:
   Not sure about this change as sys/types.h includes nuttx/config.h as the 
first line



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