r25602: don't imply "system/network.h" within replace.h,
authorStefan Metzmacher <metze@samba.org>
Wed, 10 Oct 2007 10:09:06 +0000 (12:09 +0200)
committerStefan Metzmacher <metze@samba.org>
Fri, 21 Dec 2007 04:42:47 +0000 (05:42 +0100)
as this brings in the socket_wrapper.h in unexpected
code and we endup with a missing 'swrap_close' while linking

metze
(This used to be commit 507d5ca7d994f0771dbb66e61d2d22e391508658)

source4/lib/replace/replace.h
source4/lib/replace/system/network.h

index fcf75635a705707d34118fb00f8a33bbe6d23240..e42d5ff168ef864451ffc0cc81b1738ddc9719ff 100644 (file)
@@ -325,15 +325,19 @@ ssize_t rep_pread(int __fd, void *__buf, size_t __nbytes, off_t __offset);
 ssize_t rep_pwrite(int __fd, const void *__buf, size_t __nbytes, off_t __offset);
 #endif
 
+#ifdef REPLACE_INET_NTOA
+#define inet_ntoa rep_inet_ntoa
+/* prototype is in "system/network.h" */
+#endif
+
 #ifndef HAVE_INET_PTON
-int rep_inet_pton(int af, const char *src, void *dst);
 #define inet_pton rep_inet_pton
+/* prototype is in "system/network.h" */
 #endif
 
 #ifndef HAVE_INET_NTOP
-#include "system/network.h"
-const char *rep_inet_ntop(int af, const void *src, char *dst, socklen_t size);
 #define inet_ntop rep_inet_ntop
+/* prototype is in "system/network.h" */
 #endif
 
 #ifdef HAVE_LIMITS_H
index 02942f9a4435bf574b1b4a249f12a32823123b64..8b911cf7d36c70b6a3211b8a86d4d4748590e659 100644 (file)
 #endif
 
 #ifdef REPLACE_INET_NTOA
+/* define is in "replace.h" */
 char *rep_inet_ntoa(struct in_addr ip);
-#define inet_ntoa rep_inet_ntoa
+#endif
+
+#ifndef HAVE_INET_PTON
+/* define is in "replace.h" */
+int rep_inet_pton(int af, const char *src, void *dst);
+#endif
+
+#ifndef HAVE_INET_NTOP
+/* define is in "replace.h" */
+const char *rep_inet_ntop(int af, const void *src, char *dst, socklen_t size);
 #endif
 
 /*