From 3240f01636db144f765ec193de10196106537eb9 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sat, 19 Mar 2005 06:07:33 +0000 Subject: r5898: Handle errors in the 'sync' name and IP address handling code. Andrew Bartlett (This used to be commit 6b8b40f73bd8b7ce23effc8eb1d808db77bcbf8b) --- source4/lib/socket/socket_ipv4.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source4/lib/socket/socket_ipv4.c b/source4/lib/socket/socket_ipv4.c index 4f8b1e6dd6..93ddf68046 100644 --- a/source4/lib/socket/socket_ipv4.c +++ b/source4/lib/socket/socket_ipv4.c @@ -111,6 +111,9 @@ static NTSTATUS ipv4_connect(struct socket_context *sock, } srv_ip = interpret_addr2(srv_address); + if (!srv_ip.addr) { + return NT_STATUS_BAD_NETWORK_NAME; + } ZERO_STRUCT(srv_addr); #ifdef HAVE_SOCK_SIN_LEN -- cgit