From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:52652) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SYgr7-0003JN-B6 for qemu-devel@nongnu.org; Sun, 27 May 2012 13:02:14 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SYgr5-0000pV-LK for qemu-devel@nongnu.org; Sun, 27 May 2012 13:02:12 -0400 Received: from mout.web.de ([212.227.15.4]:51038) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SYgr5-0000pL-CH for qemu-devel@nongnu.org; Sun, 27 May 2012 13:02:11 -0400 From: =?UTF-8?q?Andreas=20F=C3=A4rber?= Date: Sun, 27 May 2012 19:02:08 +0200 Message-Id: <1338138128-53411-1-git-send-email-andreas.faerber@web.de> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [Qemu-devel] [PATCH for-1.1?] slirp: Avoid redefining MAX_TCPOPTLEN List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , =?UTF-8?q?Andreas=20F=C3=A4rber?= , Jan Kiszka MAX_TCPOPTLEN is being defined as 32. Darwin has it as 40, causing a warning. The value is only used to declare an array, into which currently 4 bytes are written at most. It should therefore be acceptable to adopt the host's definition. Therefore only define MAX_TCPOPTLEN if not already defined. Signed-off-by: Andreas Färber --- slirp/tcp_output.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/slirp/tcp_output.c b/slirp/tcp_output.c index 779314b..9815123 100644 --- a/slirp/tcp_output.c +++ b/slirp/tcp_output.c @@ -47,7 +47,9 @@ static const u_char tcp_outflags[TCP_NSTATES] = { }; +#ifndef MAX_TCPOPTLEN #define MAX_TCPOPTLEN 32 /* max # bytes that go in options */ +#endif /* * Tcp output routine: figure out what should be sent and send it. -- 1.7.5.3