Преглед изворни кода

Allow corotypes.h to be included from C++ code.

Michael van der Westhuizen пре 12 година
родитељ
комит
298a993552
1 измењених фајлова са 8 додато и 0 уклоњено
  1. 8 0
      include/corosync/corotypes.h

+ 8 - 0
include/corosync/corotypes.h

@@ -41,6 +41,10 @@
 #include <time.h>
 #include <sys/time.h>
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 typedef int64_t cs_time_t;
 
 #define CS_FALSE 0
@@ -136,5 +140,9 @@ cs_error_t qb_to_cs_error (int result);
 const char * cs_strerror(cs_error_t err);
 cs_error_t hdb_error_to_cs (int res);
 
+#ifdef __cplusplus
+}
+#endif
+
 #endif /* COROTYPES_H_DEFINED */