From 569200b6d46fde56f7dff5181eeb72970b3281b4 Mon Sep 17 00:00:00 2001 From: "Richard W.M. Jones" Date: Wed, 23 Jan 2008 14:50:14 +0000 Subject: [PATCH] Remove DOS line-endings. * src/socketcompat.h: Remove DOS line-endings in this file. --- ChangeLog | 5 ++ src/socketcompat.h | 120 ++++++++++++++++++++++----------------------- 2 files changed, 65 insertions(+), 60 deletions(-) diff --git a/ChangeLog b/ChangeLog index c9b253e37f..91f06399dd 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Wed Jan 23 14:43:00 BST 2008 Richard W.M. Jones + + Remove DOS line-endings. + * src/socketcompat.h: Remove DOS line-endings in this file. + Tue Jan 22 16:27:47 EST 2008 Daniel P. Berrange * configure.ac: Remove use of PKG_CHECK_EXISTS macro. Avoid diff --git a/src/socketcompat.h b/src/socketcompat.h index 0a8884cb50..f9353f171a 100644 --- a/src/socketcompat.h +++ b/src/socketcompat.h @@ -1,60 +1,60 @@ -/* - * socketcompat.h: Socket compatibility for Windows, making it slightly - * less painful to use. - * - * Use this header under the following circumstances: - * (a) Instead of including any of: , , - * , , , AND - * (b) The file will be part of what is built on Windows (basically - * just remote client stuff). - * - * You need to use socket_errno() instead of errno to get socket - * errors. - * - * Copyright (C) 2008 Red Hat, Inc. - * - * See COPYING.LIB for the License of this software - * - * Richard W.M. Jones - */ - -#ifndef __SOCKETCOMPAT_H__ -#define __SOCKETCOMPAT_H__ - -#include - -#include - -#ifndef HAVE_WINSOCK2_H /* Unix & Cygwin. */ - -#include -#include -#include -#include - -static inline int -socket_errno (void) -{ - return errno; -} - -#else /* MinGW & Win32 */ - -#include - -/* Socket functions in Windoze don't set errno. Instead of using errno - * to test for socket errors, call this function to get the errno. - */ -static inline int -socket_errno (void) -{ - return WSAGetLastError (); -} - -/* Compatibility. */ -#define EWOULDBLOCK WSAEWOULDBLOCK -#define ECONNREFUSED WSAECONNREFUSED - -#endif /* HAVE_WINSOCK2_H */ - -#endif /* __WINSOCKWRAPPER_H__ */ +/* + * socketcompat.h: Socket compatibility for Windows, making it slightly + * less painful to use. + * + * Use this header under the following circumstances: + * (a) Instead of including any of: , , + * , , , AND + * (b) The file will be part of what is built on Windows (basically + * just remote client stuff). + * + * You need to use socket_errno() instead of errno to get socket + * errors. + * + * Copyright (C) 2008 Red Hat, Inc. + * + * See COPYING.LIB for the License of this software + * + * Richard W.M. Jones + */ + +#ifndef __SOCKETCOMPAT_H__ +#define __SOCKETCOMPAT_H__ + +#include + +#include + +#ifndef HAVE_WINSOCK2_H /* Unix & Cygwin. */ + +#include +#include +#include +#include + +static inline int +socket_errno (void) +{ + return errno; +} + +#else /* MinGW & Win32 */ + +#include + +/* Socket functions in Windoze don't set errno. Instead of using errno + * to test for socket errors, call this function to get the errno. + */ +static inline int +socket_errno (void) +{ + return WSAGetLastError (); +} + +/* Compatibility. */ +#define EWOULDBLOCK WSAEWOULDBLOCK +#define ECONNREFUSED WSAECONNREFUSED + +#endif /* HAVE_WINSOCK2_H */ + +#endif /* __WINSOCKWRAPPER_H__ */