Module: wine Branch: master Commit: 920f654ffb73688ee92af049c6c866f4eea3af1e URL: https://source.winehq.org/git/wine.git/?a=commit;h=920f654ffb73688ee92af049c...
Author: Zebediah Figura z.figura12@gmail.com Date: Mon May 10 10:19:43 2021 -0500
server: Avoid calling get_unix_fd() in IOCTL_AFD_CREATE.
Signed-off-by: Zebediah Figura z.figura12@gmail.com Signed-off-by: Alexandre Julliard julliard@winehq.org
---
server/sock.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/server/sock.c b/server/sock.c index 36fda31f9c1..24a826e4ce5 100644 --- a/server/sock.c +++ b/server/sock.c @@ -1087,7 +1087,6 @@ static int init_socket( struct sock *sock, int family, int type, int protocol, u return -1; } sock_reselect( sock ); - clear_error(); return 0; }
@@ -1354,7 +1353,7 @@ static int sock_ioctl( struct fd *fd, ioctl_code_t code, struct async *async )
assert( sock->obj.ops == &sock_ops );
- if (get_unix_fd( fd ) == -1 && code != IOCTL_AFD_CREATE) return 0; + if (code != IOCTL_AFD_CREATE && get_unix_fd( fd ) < 0) return 0;
switch(code) {