diff options
Diffstat (limited to 'slirp/socket.c')
-rw-r--r-- | slirp/socket.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/slirp/socket.c b/slirp/socket.c index d8fbe89a74..207109c7ec 100644 --- a/slirp/socket.c +++ b/slirp/socket.c @@ -552,7 +552,8 @@ sosendto(struct socket *so, struct mbuf *m) slirp->vnetwork_addr.s_addr) { /* It's an alias */ if (so->so_faddr.s_addr == slirp->vnameserver_addr.s_addr) { - addr.sin_addr = dns_addr; + if (get_dns_addr(&addr.sin_addr) < 0) + addr.sin_addr = loopback_addr; } else { addr.sin_addr = loopback_addr; } |