From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LPHfp-00062N-V7 for qemu-devel@nongnu.org; Tue, 20 Jan 2009 09:33:50 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LPHfo-000623-9w for qemu-devel@nongnu.org; Tue, 20 Jan 2009 09:33:49 -0500 Received: from [199.232.76.173] (port=40000 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LPHfo-000620-6a for qemu-devel@nongnu.org; Tue, 20 Jan 2009 09:33:48 -0500 Received: from mx2.redhat.com ([66.187.237.31]:59225) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LPHfl-0007oG-7I for qemu-devel@nongnu.org; Tue, 20 Jan 2009 09:33:46 -0500 From: Avi Kivity Date: Tue, 20 Jan 2009 16:33:31 +0200 Message-Id: <1232462011-28073-1-git-send-email-avi@redhat.com> Subject: [Qemu-devel] [PATCH] Use broadcast address for slirp dhcp replies Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Anthony Liguori , qemu-devel@nongnu.org Windows Vista drops unicast dhcp replies to its yet-unconfigured address, so use a broadcast address. This behaviour is allowed by the RFC. Signed-off-by: Avi Kivity --- slirp/bootp.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/slirp/bootp.c b/slirp/bootp.c index bf704ab..ca177f4 100644 --- a/slirp/bootp.c +++ b/slirp/bootp.c @@ -191,6 +191,8 @@ static void bootp_reply(struct bootp_t *bp) rbp->bp_yiaddr = daddr.sin_addr; /* Client IP address */ rbp->bp_siaddr = saddr.sin_addr; /* Server IP address */ + daddr.sin_addr.s_addr = 0xffffffffu; + q = rbp->bp_vend; memcpy(q, rfc1533_cookie, 4); q += 4; -- 1.6.0.6