Fix issues that Trond found.
authorBrian Aker <brian@tangent.org>
Wed, 17 Aug 2011 19:54:59 +0000 (12:54 -0700)
committerBrian Aker <brian@tangent.org>
Wed, 17 Aug 2011 19:54:59 +0000 (12:54 -0700)
clients/memcapable.cc
clients/memcat.cc
clients/memcp.cc
clients/memparse.cc
libmemcached/common.h
libmemcached/server.h

index 9dff427eb3c2c9c88e8c5463569aa895ca8d65d6..1bb7a88a675abbc20cedacccc366331ff57d94d2 100644 (file)
 #include "poll/poll.h"
 #endif
 
-#include <assert.h>
+#include <cassert>
+#include <cerrno>
+#include <cstdio>
+#include <cstdlib>
+#include <cstring>
 #include <ctype.h>
-#include <errno.h>
 #include <fcntl.h>
 #include <inttypes.h>
 #include <pthread.h>
 #include <signal.h>
-#include <stdbool.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
 #include <sys/types.h>
 #include <unistd.h>
 
index 66ee3253b37b616700133ab17eea6c8a37374d7b..3e073650345750b35b3325855f1b4fe63af77fca 100644 (file)
@@ -9,14 +9,13 @@
  *
  */
 
-#include "config.h"
+#include <config.h>
 
+#include <cstdio>
+#include <cstring>
+#include <getopt.h>
 #include <iostream>
-#include <stdio.h>
-#include <inttypes.h>
-#include <string.h>
 #include <unistd.h>
-#include <getopt.h>
 #include <libmemcached/memcached.h>
 
 #include "utilities.h"
index 7b7454760e7e8a4cd36db8a675e91f08930fbc13..228362513905beabef0108285301d6c48f3d741f 100644 (file)
 
 #include "config.h"
 
-#include <iostream>
-#include <stdio.h>
-#include <stdlib.h>
-#include <inttypes.h>
-#include <unistd.h>
+#include <cerrno>
+#include <climits>
+#include <cstdio>
+#include <cstdlib>
+#include <cstdlib>
+#include <cstring>
+#include <fcntl.h>
 #include <getopt.h>
-#include <sys/types.h>
+#include <iostream>
+#ifdef HAVE_STRINGS_H
+#include <strings.h>
+#endif
 #include <sys/stat.h>
 #include <sys/types.h>
-#include <fcntl.h>
-#include <errno.h>
-#include <strings.h>
-#include <string.h>
 #include <sys/types.h>
-#include <stdlib.h>
-#include <limits.h>
+#include <sys/types.h>
+#include <unistd.h>
 
 
 #include <libmemcached/memcached.h>
index f9a2dcf2f5b97cfd1464fc55d386ad904bd94dda..c2557dfd325ad8c52bb311e767f9ddf17284f929 100644 (file)
@@ -38,6 +38,7 @@
 #include <config.h>
 
 #include <cstdio>
+#include <cstring>
 #include <iostream>
 
 #include <libmemcached/memcached.h>
index 5af6916c1be1982fe156f1880b930b7e9dd25bb8..f45eaffd4474894390f8d1142eb2796cdcefb61d 100644 (file)
 #include <sys/types.h>
 #include <unistd.h>
 
+#ifdef HAVE_STRINGS_H
+#include <strings.h>
+#endif
+
 #include <libmemcached/memcached.h>
 #include <libmemcached/watchpoint.h>
 #include <libmemcached/is.h>
index dc1121531d422736a033d481b228dce8ff08dbac..40328ab6e6cbda2d2209b505a9f6e9bf007cb6c8 100644 (file)
 
 #pragma once
 
+#ifndef WIN32
+#include <netdb.h>
+#endif
+
 enum memcached_server_state_t {
   MEMCACHED_SERVER_STATE_NEW, // fd == -1, no address lookup has been done
   MEMCACHED_SERVER_STATE_ADDRINFO, // ADDRRESS information has been gathered