summaryrefslogtreecommitdiffstats
path: root/src/jemalloc_cpp.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/jemalloc_cpp.cpp')
-rw-r--r--src/jemalloc_cpp.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/jemalloc_cpp.cpp b/src/jemalloc_cpp.cpp
index b6d7c9a..71999a8 100644
--- a/src/jemalloc_cpp.cpp
+++ b/src/jemalloc_cpp.cpp
@@ -2,9 +2,17 @@
#include <new>
#define JEMALLOC_CPP_CPP_
+#ifdef __cplusplus
+extern "C" {
+#endif
+
#include "jemalloc/internal/jemalloc_preamble.h"
#include "jemalloc/internal/jemalloc_internal_includes.h"
+#ifdef __cplusplus
+}
+#endif
+
// All operators in this file are exported.
// Possibly alias hidden versions of malloc and sdallocx to avoid an extra plt