From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1KPh81-0000Nu-LL for qemu-devel@nongnu.org; Sun, 03 Aug 2008 13:12:21 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1KPh7z-0000Nh-3r for qemu-devel@nongnu.org; Sun, 03 Aug 2008 13:12:21 -0400 Received: from [199.232.76.173] (port=59119 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1KPh7y-0000Ne-UB for qemu-devel@nongnu.org; Sun, 03 Aug 2008 13:12:18 -0400 Received: from an-out-0708.google.com ([209.85.132.247]:5506) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1KPh7y-0001h4-Ch for qemu-devel@nongnu.org; Sun, 03 Aug 2008 13:12:18 -0400 Received: by an-out-0708.google.com with SMTP id d18so509746and.130 for ; Sun, 03 Aug 2008 10:12:15 -0700 (PDT) Message-ID: <4895E6CC.6040906@codemonkey.ws> Date: Sun, 03 Aug 2008 12:11:40 -0500 From: Anthony Liguori MIME-Version: 1.0 Subject: Re: [Qemu-devel] [PATCH v2] Fix compilation of nbd on Windows References: <20080704092849.5BC0.20F538E7@nsfocus.com> <20080704023451.GO7007@networkno.de> <20080704115101.5BC9.20F538E7@nsfocus.com> <1215160927.3802.4.camel@frecb07144> <20080704203231.GB31670@networkno.de> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Laurent Vivier , chenqing Johannes Schindelin wrote: > This still only supports the client side, and only the TCP version of > it, since Windows does not have Unix sockets. > This patch fixes the build of qemu-nbd but breaks the build of qemu for win32. > Signed-off-by: Johannes Schindelin > --- > > diff --git a/qemu_socket.h b/qemu_socket.h > index 5229c24..73e05d8 100644 > --- a/qemu_socket.h > +++ b/qemu_socket.h > @@ -10,9 +10,27 @@ > > #define socket_error() WSAGetLastError() > #undef EINTR > +#undef EINVAL > #define EWOULDBLOCK WSAEWOULDBLOCK > #define EINTR WSAEINTR > #define EINPROGRESS WSAEINPROGRESS > +#define EINVAL WSAEINVAL > + > +static inline int inet_aton(const char *cp, struct in_addr *inp) > +{ > + unsigned long result = inet_addr(cp); > + if (result == INADDR_NONE) > + return 0; > + inp->s_addr = result; > + return 1; > +} > This bit conflicts with: > #include > int inet_aton(const char *cp, struct in_addr *ia); > #endif This definition in vl.c Regards, Anthony Liguori