mirror of
https://github.com/samba-team/samba.git
synced 2025-02-02 09:47:23 +03:00
s4:lib/socket: don't pass -1 to close()
metze
This commit is contained in:
parent
8b375eef24
commit
8386b20799
@ -58,7 +58,10 @@ static NTSTATUS ipv4_init(struct socket_context *sock)
|
|||||||
|
|
||||||
static void ip_close(struct socket_context *sock)
|
static void ip_close(struct socket_context *sock)
|
||||||
{
|
{
|
||||||
close(sock->fd);
|
if (sock->fd != -1) {
|
||||||
|
close(sock->fd);
|
||||||
|
sock->fd = -1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static NTSTATUS ip_connect_complete(struct socket_context *sock, uint32_t flags)
|
static NTSTATUS ip_connect_complete(struct socket_context *sock, uint32_t flags)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user