]> granicus.if.org Git - icinga2/commitdiff
UnbufferedAsioTlsStream: don't rely on *this in decltype()s for methods' return types
authorAlexander A. Klimov <alexander.klimov@icinga.com>
Tue, 12 Mar 2019 10:47:53 +0000 (11:47 +0100)
committerAlexander A. Klimov <alexander.klimov@icinga.com>
Mon, 1 Apr 2019 11:31:16 +0000 (13:31 +0200)
lib/base/tlsstream.hpp

index 5f5fc6d7399a9e5af64594939c526da0dcd308a3..6156a3d2f80eaba71550478c49d610be7ba8be3d 100644 (file)
@@ -122,7 +122,7 @@ public:
 
        template<class... Args>
        inline
-       auto async_handshake(handshake_type type, Args&&... args) -> decltype(AsioTcpTlsStream::async_handshake(type, std::forward<Args>(args)...))
+       auto async_handshake(handshake_type type, Args&&... args) -> decltype(((AsioTcpTlsStream*)nullptr)->async_handshake(type, std::forward<Args>(args)...))
        {
                BeforeHandshake(type);
 
@@ -131,7 +131,7 @@ public:
 
        template<class... Args>
        inline
-       auto handshake(handshake_type type, Args&&... args) -> decltype(AsioTcpTlsStream::handshake(type, std::forward<Args>(args)...))
+       auto handshake(handshake_type type, Args&&... args) -> decltype(((AsioTcpTlsStream*)nullptr)->handshake(type, std::forward<Args>(args)...))
        {
                BeforeHandshake(type);