Просмотр исходного кода

fix: 修正一批未正确include的编译警告

Wendal Chen 2 лет назад
Родитель
Сommit
bd62d445ac

+ 1 - 0
components/cmux/luat_cmux.c

@@ -5,6 +5,7 @@ LuatOS cmux
 #include "luat_base.h"
 #include "luat_msgbus.h"
 #include "luat_malloc.h"
+#include "stdlib.h"
 
 #define LUAT_LOG_TAG "cmux"
 #include "luat_log.h"

+ 1 - 1
components/gmssl/src/asn1.c

@@ -22,7 +22,7 @@
 #include <gmssl/error.h>
 #include <gmssl/endian.h>
 
-
+int isascii(int c);
 static const char *asn1_tag_index[] = {
 	"[0]",  "[1]",  "[2]",  "[3]",  "[4]",  "[5]",  "[6]",  "[7]",  "[8]",  "[9]",
 	"[10]", "[11]", "[12]", "[13]", "[14]", "[15]", "[16]", "[17]", "[18]", "[19]",

+ 2 - 0
components/lua-cjson/lua_cjson.c

@@ -64,6 +64,8 @@
 //#include <lrodefs.h>
 //#include <auxmods.h>
 
+int strncasecmp(const char *string1, const char *string2, size_t count);
+
 static char float_fmt[12];
 
 #ifdef WIN32

+ 2 - 0
components/multimedia/luat_lib_multimedia_codec.c

@@ -11,6 +11,8 @@
 #include "luat_multimedia.h"
 #include "luat_msgbus.h"
 #include "luat_zbuff.h"
+#include "luat_fs.h"
+#include "luat_malloc.h"
 #define LUAT_LOG_TAG "codec"
 #include "luat_log.h"
 #ifdef LUAT_SUPPORT_AMR

+ 1 - 0
components/multimedia/minimp3.c

@@ -1,5 +1,6 @@
 
 #include "mp3_decode/minimp3.h"
+#include "luat_malloc.h"
 extern void DBG_Printf(const char* format, ...);
 #define DBG(x,y...)		DBG_Printf("%s %d:"x"\r\n", __FUNCTION__,__LINE__,##y)
 #define _MINIMP3_IMPLEMENTATION_GUARD

+ 2 - 1
components/network/libhttp/luat_http_client.c

@@ -1,6 +1,5 @@
 
 #include "luat_base.h"
-#include <string.h>
 #include "luat_network_adapter.h"
 #include "luat_rtos.h"
 // #include "luat_msgbus.h"
@@ -22,6 +21,8 @@
 // #define LLOGD	DBG
 #endif
 
+int strncasecmp(const char *string1, const char *string2, size_t count);
+
 static void http_send_message(luat_http_ctrl_t *http_ctrl);
 int32_t luat_lib_http_callback(void *data, void *param);
 void luat_http_client_onevent(luat_http_ctrl_t *http_ctrl, int arg1, int arg2);

+ 3 - 0
components/ymodem/luat_ymodem.c

@@ -1,6 +1,9 @@
+#include "luat_base.h"
+#include "stdlib.h"
 #include "luat_ymodem.h"
 #include "luat_fs.h"
 #include "luat_malloc.h"
+#include "luat_timer.h"
 
 #define LUAT_LOG_TAG "ymodem"
 #include "luat_log.h"