From b5ab0c5285c356ab4e66be32bad90ddfefd3b727 Mon Sep 17 00:00:00 2001 From: goldsimon Date: Tue, 22 May 2007 20:32:22 +0000 Subject: [PATCH] Included some missing braces in lwip_send & lwip_sendto (if !LWIP_UDP && !LWIP_RAW) --- src/api/sockets.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/api/sockets.c b/src/api/sockets.c index aaf8a29c..4095c805 100644 --- a/src/api/sockets.c +++ b/src/api/sockets.c @@ -477,13 +477,14 @@ lwip_send(int s, const void *data, int size, unsigned int flags) if (!sock) return -1; - if (sock->conn->type!=NETCONN_TCP) + if (sock->conn->type!=NETCONN_TCP) { #if (LWIP_UDP || LWIP_RAW) return lwip_sendto(s, data, size, flags, NULL, 0); #else sock_set_errno(sock, err_to_errno(ERR_ARG)); return -1; #endif /* (LWIP_UDP || LWIP_RAW) */ + } err = netconn_write(sock->conn, data, size, NETCONN_COPY); @@ -506,13 +507,14 @@ lwip_sendto(int s, const void *data, int size, unsigned int flags, if (!sock) return -1; - if (sock->conn->type==NETCONN_TCP) + if (sock->conn->type==NETCONN_TCP) { #if LWIP_TCP return lwip_send(s, data, size, flags); #else sock_set_errno(sock, err_to_errno(ERR_ARG)); return -1; #endif /* LWIP_TCP */ + } LWIP_ASSERT("lwip_sendto: invalid address", (((to==NULL) && (tolen==0)) || ((tolen == sizeof(struct sockaddr_in)) &&