Permalink
Browse files

Don't include stdbool.h when included from C++

  • Loading branch information...
trondn committed Aug 12, 2011
1 parent cb6290c commit bbafc072774d49b6c85bc4c3788a343640e67066
Showing with 11 additions and 2 deletions.
  1. +4 −1 include/memcached/engine.h
  2. +3 −0 include/memcached/extension.h
  3. +4 −1 include/memcached/types.h
@@ -2,8 +2,11 @@
#ifndef MEMCACHED_ENGINE_H
#define MEMCACHED_ENGINE_H
-#include <sys/types.h>
+#ifndef __cplusplus
#include <stdbool.h>
+#endif
+
+#include <sys/types.h>
#include <stdint.h>
#include <stdio.h>
@@ -2,7 +2,10 @@
#ifndef MEMCACHED_EXTENSION_H
#define MEMCACHED_EXTENSION_H
+#ifndef __cplusplus
#include <stdbool.h>
+#endif
+
#include <stdint.h>
#include <memcached/engine_common.h>
#include <memcached/protocol_binary.h>
@@ -2,9 +2,12 @@
#define MEMCACHED_TYPES_H 1
#include <sys/types.h>
-#include <stdbool.h>
#include <stdint.h>
+#ifndef __cplusplus
+#include <stdbool.h>
+#endif
+
#ifdef __WIN32__
struct iovec {
size_t iov_len;

0 comments on commit bbafc07

Please sign in to comment.