From 7e7aa6aaee65c3752994d6717c582e222103e2f1 Mon Sep 17 00:00:00 2001 From: Dennis Luxen Date: Sun, 11 May 2014 16:51:14 +0200 Subject: [PATCH] workaround incomplete std::shared_ptr compatibility of old boost versions --- Server/Connection.h | 29 ++++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git a/Server/Connection.h b/Server/Connection.h index 174077ccc..122d4fe4a 100644 --- a/Server/Connection.h +++ b/Server/Connection.h @@ -35,10 +35,33 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include +#include +#include + + #include + #include + #include + +//workaround for incomplete std::shared_ptr compatibility in old boost versions +#if BOOST_VERSION < 105300 || defined BOOST_NO_CXX11_SMART_PTR + +namespace boost { +template +const T* get_pointer(std::shared_ptr const& p) +{ + return p.get(); +} + +template +T* get_pointer(std::shared_ptr& p) +{ + return p.get(); +} +} // namespace boost + +#endif + -#include -#include -#include class RequestHandler;