lwip_fcntl/F_GETFL: no need to check sock->conn != NULL: already checked by get_socket()

This commit is contained in:
goldsimon 2017-03-29 22:26:34 +02:00
parent 5b6c654dd1
commit ca9f57c09f

View File

@ -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;
}