p9y: bsd
authorMichael Wallner <mike@php.net>
Thu, 3 Dec 2020 18:46:35 +0000 (19:46 +0100)
committerMichael Wallner <mike@php.net>
Thu, 3 Dec 2020 18:46:35 +0000 (19:46 +0100)
13 files changed:
CMake/_Include.cmake
src/libmemcached/behavior.cc
src/libmemcached/common.h
src/libmemcached/connect.cc
src/libmemcached/flush_buffers.cc
src/libmemcached/instance.cc
src/libmemcached/io.cc
src/libmemcached/purge.cc
src/libmemcached/sasl.cc
src/libmemcached/server.cc
src/libmemcachedprotocol/pedantic.c
src/p9y/socket.hpp
test/lib/Connection.hpp

index a419d8dfdc0b023fff9106e7b3ef8635807764f9..79533f2766b6d228bac54755619a3c5ddaa74598 100644 (file)
@@ -121,6 +121,7 @@ check_include(dlfcn.h)
 check_include(getopt.h)
 check_include(libgen.h)
 check_include(netdb.h)
+check_include(netinet/in.h)
 check_include(poll.h)
 check_include(strings.h)
 check_include(sys/poll.h)
index d0d6c6f2a9c0e416f6e732b0e5c405645fae5807..acb0fe1af69c40ffa788895282c3698a19cb3909 100644 (file)
@@ -17,7 +17,6 @@
 #include "libmemcached/options.hpp"
 #include "libmemcached/virtual_bucket.h"
 #include "p9y/random.hpp"
-#include "p9y/socket.hpp"
 
 #include <ctime>
 #include <sys/types.h>
index defb3b0da19b31ab7b79662e3d6e5c2bc9111dd3..c36384b2aafc170654a8e3a19d90577c7bdeccfb 100644 (file)
 #  include <iso646.h>
 #endif
 
-#ifdef HAVE_SYS_UN_H
-#  include <sys/un.h>
-#endif
+#include "p9y/socket.hpp"
 
 #ifdef HAVE_SYS_TIME_H
 #  include <sys/time.h>
 #endif
 
 #include <fcntl.h>
-#include <sys/types.h>
-
-#ifdef HAVE_UNISTD_H
-#  include <unistd.h>
-#endif
-
-#ifdef HAVE_SYS_SOCKET_H
-#  include <sys/socket.h>
-#endif
 
 #ifdef HAVE_STRINGS_H
 #  include <strings.h>
index 913e48be21dc593c8b3da2aaa48ef3ba891ef611..a4b9b40aee613c418f3fbdf2bbf714d357cbf470 100644 (file)
@@ -14,7 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-#include "p9y/socket.hpp"
 #include "p9y/poll.hpp"
 
 #include <cassert>
index 6c58e69cd902c56f2dde262213b19415350db281..512fa2b7a429681419a061d330cf938ca248b013 100644 (file)
@@ -14,7 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-#include "p9y/socket.hpp"
 
 memcached_return_t memcached_flush_buffers(memcached_st *shell) {
   Memcached *memc = memcached2Memcached(shell);
index 972f6b6f6ae5e3f6e3cfacd4f2b4aa3f82a023a9..266eccc70f8d8b6f53b73b1513ab7879ff5447e6 100644 (file)
@@ -14,7 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-#include "p9y/socket.hpp"
 
 static inline void _server_init(memcached_instance_st *self, Memcached *root,
                                 const memcached_string_t &hostname, in_port_t port, uint32_t weight,
index 94aca6177acc929f50811fa1276810de621c02fc..0cf1931a3add659a99d3180b79a9e261b668677d 100644 (file)
@@ -14,8 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-
-#include "p9y/socket.hpp"
 #include "p9y/poll.hpp"
 
 void initialize_binary_request(memcached_instance_st *server,
index d4b3146da983790322440437337da27901b3f233..4437d76100b53354b9c660107c5014d2975eae9d 100644 (file)
@@ -14,7 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-#include "p9y/socket.hpp"
 
 #define memcached_set_purging(__object, __value) ((__object)->state.is_purging = (__value))
 
index 4fa981d285cf6a03c047d1acd1ebbaa391e49932..437499b06008da8fada787e70f4828a52bb9b647 100644 (file)
@@ -14,7 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-#include "p9y/socket.hpp"
 
 #include <cassert>
 #include <atomic>
index 28d063ec05d494fd648419eda53c48e710dcd587..e038196abffd52fe8d3052e7365ec10c2d0c9f79 100644 (file)
@@ -14,7 +14,6 @@
 */
 
 #include "libmemcached/common.h"
-#include "p9y/socket.hpp"
 
 static inline void _server_init(memcached_server_st *self, Memcached *root,
                                 const memcached_string_t &hostname, in_port_t port, uint32_t weight,
index 9b7d728fc0fd92b1dbc0d5f7e91677d90186521b..c966ee8bb8fed9e5ba36d1896f80e8edb9ea92f3 100644 (file)
@@ -14,8 +14,7 @@
 */
 
 #include "libmemcachedprotocol/common.h"
-
-#include <sys/types.h>
+#include "p9y/socket.hpp"
 
 #define ensure(a) \
   if (!(a)) { \
index 339b5995bf285465e160c8989b12c563fdda8a5b..ca0b97d3a5f140ec48cf6bc9b71ecfb56489fe50 100644 (file)
 # include <sys/socket.h>
 #endif
 
+#if defined HAVE_NETINET_IN_H
+# include <netinet/in.h>
+#endif
+
 #if defined HAVE_SYS_UN_H
 # include <sys/un.h>
 #endif
index f087a697423f38b9d159d360ce92080159441032..bcb78e4a9bf18e7a6005c89dd31e37bf94a4f568 100644 (file)
@@ -18,6 +18,7 @@
 #include "common.hpp"
 
 #include <sys/socket.h>
+#include <netinet/in.h>
 #include <sys/un.h>
 
 class Connection {