Sfoglia il codice sorgente

【完善】:整理代码,去除一些警告

SummerGift 6 anni fa
parent
commit
f3f0924a17

+ 1 - 1
azure-port/pal/inc/socket_async_os.h

@@ -14,4 +14,4 @@
 #include "lwip/sockets.h"
 #include "lwip/netdb.h"
 
-#endif // SOCKET_ASYNC_OS_H
+#endif // SOCKET_ASYNC_OS_H

+ 4 - 6
azure-port/pal/src/azure_platform.c

@@ -16,16 +16,14 @@
 int platform_init(void)
 {
     time_t result = ntp_sync_to_rtc(NETUTILS_NTP_HOSTNAME);
-    
+
     if (result > 0)
     {
-        rt_kprintf("\nntp init\n");
+        rt_kprintf("ntp init successful.\n");
         return RT_EOK;
+    }
 
-    }else if( result == 0)
-    {
-        return RT_ERROR;
-    }   
+    return -RT_ERROR;
 }
 
 const IO_INTERFACE_DESCRIPTION* platform_get_default_tlsio(void)

+ 1 - 1
azure/c-utility/inc/azure_c_shared_utility/tls_config.h

@@ -7,4 +7,4 @@
 //#define USE_WOLF_SSL
 #define USE_MBED_TLS
 
-#endif // __TLS_CONFIG_H__
+#endif // __TLS_CONFIG_H__