From ca9f57c09f0128c9ee39d4c28f90124056e08448 Mon Sep 17 00:00:00 2001 From: goldsimon Date: Wed, 29 Mar 2017 22:26:34 +0200 Subject: [PATCH] lwip_fcntl/F_GETFL: no need to check sock->conn != NULL: already checked by get_socket() --- src/api/sockets.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/sockets.c b/src/api/sockets.c index c250f62c..517a957d 100644 --- a/src/api/sockets.c +++ b/src/api/sockets.c @@ -3177,7 +3177,7 @@ lwip_fcntl(int s, int cmd, int val) but locking should be OK as well since we only *read* some flags */ SYS_ARCH_PROTECT(lev); #endif - if (sock->conn && sock->conn->pcb.tcp) { + if (sock->conn->pcb.tcp) { if(!(sock->conn->pcb.tcp->flags & TF_RXCLOSED)) { op_mode |= O_RDONLY; }