Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MveJQ-0003DM-VO for qemu-devel@nongnu.org; Wed, 07 Oct 2009 17:44:45 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MveJM-00038A-0t for qemu-devel@nongnu.org; Wed, 07 Oct 2009 17:44:44 -0400 Received: from [199.232.76.173] (port=55873 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MveJL-00037y-Ra for qemu-devel@nongnu.org; Wed, 07 Oct 2009 17:44:39 -0400 Received: from mx1.redhat.com ([209.132.183.28]:16228) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MveJJ-0003Re-Pk for qemu-devel@nongnu.org; Wed, 07 Oct 2009 17:44:38 -0400 Received: from int-mx03.intmail.prod.int.phx2.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id n97LiaiV015742 for ; Wed, 7 Oct 2009 17:44:36 -0400 From: Juan Quintela Date: Wed, 7 Oct 2009 23:44:15 +0200 Message-Id: <1254951855-21698-1-git-send-email-quintela@redhat.com> Subject: [Qemu-devel] [PATCH] slirp: fix !CONFIG_SLIRP compilation List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: markmc@redhat.com This moves the code that depens on slirp under CONFIG_SLIRP again. Signed-off-by: Juan Quintela --- net.c | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/net.c b/net.c index 2e4dd58..e93017d 100644 --- a/net.c +++ b/net.c @@ -2451,6 +2451,7 @@ static int net_init_nic(QemuOpts *opts, Monitor *mon) return idx; } +#if defined(CONFIG_SLIRP) static int net_init_slirp_configs(const char *name, const char *value, void *opaque) { struct slirp_config_str *config; @@ -2546,6 +2547,7 @@ static int net_init_slirp(QemuOpts *opts, Monitor *mon) return ret; } +#endif /* CONFIG_SLIRP */ #ifdef _WIN32 static int net_init_tap_win32(QemuOpts *opts, Monitor *mon) @@ -3227,6 +3229,7 @@ int net_init_clients(void) int net_client_parse(const char *optarg) { +#if defined(CONFIG_SLIRP) /* handle legacy -net channel,port:chr */ if (!strncmp(optarg, "channel,", strlen("channel,"))) { int ret; @@ -3248,7 +3251,7 @@ int net_client_parse(const char *optarg) return ret; } - +#endif if (!qemu_opts_parse(&qemu_net_opts, optarg, "type")) { return -1; } -- 1.6.2.5