From 5066ba6a0ee43db9ef366f8a0d05ce91d4a02157 Mon Sep 17 00:00:00 2001 From: HubretXie Date: Tue, 2 Apr 2019 16:10:54 +0800 Subject: [PATCH] Update at_socket.c MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 修复sock未初始化使用的问题 --- components/net/at/at_socket/at_socket.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/net/at/at_socket/at_socket.c b/components/net/at/at_socket/at_socket.c index cccb35ae1a..054c5508c9 100644 --- a/components/net/at/at_socket/at_socket.c +++ b/components/net/at/at_socket/at_socket.c @@ -737,7 +737,7 @@ int at_recv(int s, void *mem, size_t len, int flags) int at_sendto(int socket, const void *data, size_t size, int flags, const struct sockaddr *to, socklen_t tolen) { - struct at_socket *sock; + struct at_socket *sock = RT_NULL; int len, result = 0; if (at_dev_ops == RT_NULL)