]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/common/ceph_context.h
update source to Ceph Pacific 16.2.2
[ceph.git] / ceph / src / common / ceph_context.h
index c101eb4a034b580afb1f0a9f7469d85eaf298454..27f76900784245a8279c1244ec5d4af109aa4d1f 100644 (file)
 #include <typeinfo>
 #include <typeindex>
 
-#include "include/common_fwd.h"
+#include <boost/intrusive_ptr.hpp>
+
 #include "include/any.h"
+#include "include/common_fwd.h"
+#include "include/compat.h"
 
 #include "common/cmdparse.h"
 #include "common/code_environment.h"
@@ -394,4 +397,17 @@ private:
 #endif
 #endif // WITH_SEASTAR
 
+#if !(defined(WITH_SEASTAR) && !defined(WITH_ALIEN)) && defined(__cplusplus)
+namespace ceph::common {
+inline void intrusive_ptr_add_ref(CephContext* cct)
+{
+  cct->get();
+}
+
+inline void intrusive_ptr_release(CephContext* cct)
+{
+  cct->put();
+}
+}
+#endif // !(defined(WITH_SEASTAR) && !defined(WITH_ALIEN)) && defined(__cplusplus)
 #endif