]> xenbits.xensource.com Git - libvirt.git/commitdiff
remove src/socketcompat.h; no longer needed
authorJim Meyering <meyering@redhat.com>
Tue, 28 Oct 2008 19:09:04 +0000 (19:09 +0000)
committerJim Meyering <meyering@redhat.com>
Tue, 28 Oct 2008 19:09:04 +0000 (19:09 +0000)
* src/socketcompat.h: Remove file.
* src/remote_internal.c: Don't include socketcompat.h.
* qemud/qemud.h: Likewise.
* qemud/remote_protocol.x: Likewise, but do include <arpa/inet.h>
for htonl.
* src/remote_internal.c: Likewise, but do include <errno.h>.
* qemud/remote_protocol.c: Regenererate.
* qemud/remote_protocol.h: Regenererate.
* src/Makefile.am (REMOTE_DRIVER_SOURCES): Remove socketcompat.h.

ChangeLog
qemud/qemud.h
qemud/remote_protocol.c
qemud/remote_protocol.h
qemud/remote_protocol.x
src/Makefile.am
src/remote_internal.c
src/socketcompat.h [deleted file]

index 1ac85e564bf974c670d08fdb5d4848859de4263c..ee119e6c6e184099f2b8bab58feaa4c50c8e8235 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,16 @@
+Tue Oct 28 19:17:20 +0100 2008 Jim Meyering <meyering@redhat.com>
+
+       remove src/socketcompat.h;  no longer needed
+       * src/socketcompat.h: Remove file.
+       * src/remote_internal.c: Don't include socketcompat.h.
+       * qemud/qemud.h: Likewise.
+       * qemud/remote_protocol.x: Likewise, but do include <arpa/inet.h>
+       for htonl.
+       * src/remote_internal.c: Likewise, but do include <errno.h>.
+       * qemud/remote_protocol.c: Regenererate.
+       * qemud/remote_protocol.h: Regenererate.
+       * src/Makefile.am (REMOTE_DRIVER_SOURCES): Remove socketcompat.h.
+
 Tue Oct 28 13:46:50 +0100 2008 Jim Meyering <meyering@redhat.com>
 
        make generated qemud/*.[ch] files read-only
index 83d65b6ee546374c6dc0d5954326fe1b149dbee3..822ed939c122cd2724fbe7c367d82e6b58a9306d 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * qemud.h: daemon data structure definitions
  *
- * Copyright (C) 2006, 2007 Red Hat, Inc.
+ * Copyright (C) 2006-2008 Red Hat, Inc.
  * Copyright (C) 2006 Daniel P. Berrange
  *
  * This library is free software; you can redistribute it and/or
@@ -27,8 +27,6 @@
 
 #include <config.h>
 
-#include "socketcompat.h"
-
 #include <gnutls/gnutls.h>
 #include <gnutls/x509.h>
 #include "gnutls_1_0_compat.h"
index 5ef80e546ae1299b42fc0e2e207ef467b13b0cd4..e0edd254cbea3016b91162478576f9af1db63a23 100644 (file)
@@ -6,7 +6,7 @@
 #include "remote_protocol.h"
 #include <config.h>
 #include "internal.h"
-#include "socketcompat.h"
+#include <arpa/inet.h>
 
 bool_t
 xdr_remote_nonnull_string (XDR *xdrs, remote_nonnull_string *objp)
index e43514d28e456a3f3195dedd22649071b75e1a39..ec1beb4c0170794d749da47d050c5346e1d5254d 100644 (file)
@@ -15,7 +15,7 @@ extern "C" {
 
 #include <config.h>
 #include "internal.h"
-#include "socketcompat.h"
+#include <arpa/inet.h>
 #define REMOTE_MESSAGE_MAX 262144
 #define REMOTE_STRING_MAX 65536
 
index b7e41aadee7057f98f6fc5b593d0e3c025aefe22..bef9711ff1a849839a090fb6ebd3dc9bc716e4b1 100644 (file)
@@ -3,7 +3,7 @@
  *   remote_internal driver and libvirtd.  This protocol is
  *   internal and may change at any time.
  *
- * Copyright (C) 2006-2007 Red Hat, Inc.
+ * Copyright (C) 2006-2008 Red Hat, Inc.
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -38,7 +38,7 @@
 
 %#include <config.h>
 %#include "internal.h"
-%#include "socketcompat.h"
+%#include <arpa/inet.h>
 
 /*----- Data types. -----*/
 
index e743f247db488138f54904885ae70b88b5590c74..8934c3c1d0fb21394933dfdbc8d3afe25495f4f8 100644 (file)
@@ -74,8 +74,7 @@ REMOTE_DRIVER_SOURCES =                                               \
                gnutls_1_0_compat.h                             \
                remote_internal.c remote_internal.h             \
                ../qemud/remote_protocol.c                      \
-               ../qemud/remote_protocol.h                      \
-               socketcompat.h
+               ../qemud/remote_protocol.h
 
 # Mock driver, covering domains, storage, networks, etc
 TEST_DRIVER_SOURCES =                                          \
index e6dcfcfe066fd3f492d7e1bd3039d5417e70716e..5b82f99079e39809698a56350fb03502b49c9237 100644 (file)
@@ -24,7 +24,8 @@
 #include <config.h>
 
 /* Windows socket compatibility functions. */
-#include "socketcompat.h"
+#include <errno.h>
+#include <sys/socket.h>
 
 #include <stdio.h>
 #include <stdlib.h>
diff --git a/src/socketcompat.h b/src/socketcompat.h
deleted file mode 100644 (file)
index a06fe36..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * 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: <net/if.h>, <netinet/in.h>,
- *     <sys/socket.h>, <netdb.h>, <netinet/tcp.h>, 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 <rjones@redhat.com>
- */
-
-#ifndef __SOCKETCOMPAT_H__
-#define __SOCKETCOMPAT_H__
-
-#include <config.h>
-
-#include <errno.h>
-#include <sys/socket.h>
-
-static inline int
-socket_errno (void)
-{
-  return errno;
-}
-
-#ifndef HAVE_WINSOCK2_H                /* Unix & Cygwin. */
-# include <sys/un.h>
-# include <net/if.h>
-# include <netinet/in.h>
-# include <netinet/tcp.h>
-#endif /* HAVE_WINSOCK2_H */
-
-#endif /* __WINSOCKWRAPPER_H__ */