From patchwork Tue Aug 7 00:34:20 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anthony Liguori X-Patchwork-Id: 175481 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 07DA52C00A3 for ; Tue, 7 Aug 2012 10:34:41 +1000 (EST) Received: from localhost ([::1]:41961 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SyXkt-0001c3-98 for incoming@patchwork.ozlabs.org; Mon, 06 Aug 2012 20:34:39 -0400 Received: from eggs.gnu.org ([208.118.235.92]:39666) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SyXkm-0001by-75 for qemu-devel@nongnu.org; Mon, 06 Aug 2012 20:34:33 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SyXkl-0001Z6-59 for qemu-devel@nongnu.org; Mon, 06 Aug 2012 20:34:32 -0400 Received: from e9.ny.us.ibm.com ([32.97.182.139]:44579) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SyXkl-0001YE-17 for qemu-devel@nongnu.org; Mon, 06 Aug 2012 20:34:31 -0400 Received: from /spool/local by e9.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Mon, 6 Aug 2012 20:34:27 -0400 Received: from d01dlp02.pok.ibm.com (9.56.250.167) by e9.ny.us.ibm.com (192.168.1.109) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Mon, 6 Aug 2012 20:34:24 -0400 Received: from d01relay07.pok.ibm.com (d01relay07.pok.ibm.com [9.56.227.147]) by d01dlp02.pok.ibm.com (Postfix) with ESMTP id 145356E803E for ; Mon, 6 Aug 2012 20:34:23 -0400 (EDT) Received: from d01av02.pok.ibm.com (d01av02.pok.ibm.com [9.56.224.216]) by d01relay07.pok.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q770YLmj22216804 for ; Mon, 6 Aug 2012 20:34:21 -0400 Received: from d01av02.pok.ibm.com (loopback [127.0.0.1]) by d01av02.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q770YLLh022014 for ; Mon, 6 Aug 2012 21:34:21 -0300 Received: from titi.austin.rr.com (sig-9-76-23-51.mts.ibm.com [9.76.23.51]) by d01av02.pok.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id q770YKDf021984; Mon, 6 Aug 2012 21:34:20 -0300 From: Anthony Liguori To: qemu-devel@nongnu.org Date: Mon, 6 Aug 2012 19:34:20 -0500 Message-Id: <1344299660-4084-1-git-send-email-aliguori@us.ibm.com> X-Mailer: git-send-email 1.7.5.4 X-Content-Scanned: Fidelis XPS MAILER x-cbid: 12080700-7182-0000-0000-000002303A33 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 32.97.182.139 Cc: Jan Kiszka , Anthony Liguori Subject: [Qemu-devel] [PATCH] slirp: fix build on mingw32 X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org in_addr_t isn't available on mingw32. Just use an unsigned long instead. I considered typedef'ing in_addr_t on mingw32 but this would potentially be brittle if mingw32 did introduce the type. Cc: Jan Kiszka Signed-off-by: Anthony Liguori --- slirp/main.h | 2 +- slirp/slirp.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/slirp/main.h b/slirp/main.h index bf601e2..1f3b84d 100644 --- a/slirp/main.h +++ b/slirp/main.h @@ -31,7 +31,7 @@ extern char *exec_shell; extern u_int curtime; extern fd_set *global_readfds, *global_writefds, *global_xfds; extern struct in_addr loopback_addr; -extern in_addr_t loopback_mask; +extern unsigned long loopback_mask; extern char *username; extern char *socket_path; extern int towrite_max; diff --git a/slirp/slirp.c b/slirp/slirp.c index 9787104..38e0a21 100644 --- a/slirp/slirp.c +++ b/slirp/slirp.c @@ -30,7 +30,7 @@ /* host loopback address */ struct in_addr loopback_addr; /* host loopback network mask */ -in_addr_t loopback_mask; +unsigned long loopback_mask; /* emulated hosts use the MAC addr 52:55:IP:IP:IP:IP */ static const uint8_t special_ethaddr[ETH_ALEN] = {