diff --git a/src/TLSClient.cpp b/src/TLSClient.cpp index 9d06b09aa..b52624536 100644 --- a/src/TLSClient.cpp +++ b/src/TLSClient.cpp @@ -32,6 +32,7 @@ #include #include #include +#include #include #include #include @@ -233,7 +234,7 @@ void TLSClient::connect (const std::string& host, const std::string& port) #if GNUTLS_VERSION_NUMBER >= 0x030109 gnutls_transport_set_int (_session, _socket); #else - gnutls_transport_set_ptr (_session, (gnutls_transport_ptr_t) _socket); + gnutls_transport_set_ptr (_session, (gnutls_transport_ptr_t) (intptr_t) _socket); #endif // Perform the TLS handshake