This is an automated email from the ASF dual-hosted git repository. astitcher pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/qpid-proton.git
The following commit(s) were added to refs/heads/master by this push: new e4e6f58 PROTON-2075: Amend ABI fix for gcc 4.4.7 - Earlier gcc do not support #pragma GCC diagnostic push/pop But it's not really necessary as we're at the very end of the TU anyway. e4e6f58 is described below commit e4e6f586100ba16ebd83cf1782ac941af03e1584 Author: Andrew Stitcher <astitc...@apache.org> AuthorDate: Fri Aug 9 11:46:56 2019 -0400 PROTON-2075: Amend ABI fix for gcc 4.4.7 - Earlier gcc do not support #pragma GCC diagnostic push/pop But it's not really necessary as we're at the very end of the TU anyway. --- cpp/src/ssl_options.cpp | 64 ++++++++++++++++++++++++------------------------- 1 file changed, 31 insertions(+), 33 deletions(-) diff --git a/cpp/src/ssl_options.cpp b/cpp/src/ssl_options.cpp index 27cfb1b..ae5999e 100644 --- a/cpp/src/ssl_options.cpp +++ b/cpp/src/ssl_options.cpp @@ -153,6 +153,37 @@ ssl_certificate::ssl_certificate(const std::string &main, const std::string &ext // Don't do this on MacOS or with Visual Studio #if !defined(_MSC_VER) && !(defined(__APPLE__) && defined(__MACH__)) +// +// These are a bit easier as the entire class has been removed so we can just define the class here +// They do rely on the impl_ member being effectively the same type and structure location from +// The previous parent type ssl_domain to ssl_server_options/ssl_client_options. +// +// PN_CPP_EXTERN proton::internal::ssl_domain::ssl_domain(const ssl_domain&); +// PN_CPP_EXTERN proton::internal::ssl_domain::ssl_domain& operator=(const ssl_domain&); +// PN_CPP_EXTERN proton::internal::ssl_domain::~ssl_domain(); +// +namespace proton { +namespace internal { +class ssl_domain { + PN_CPP_EXTERN ssl_domain(const ssl_domain&); + PN_CPP_EXTERN ssl_domain& operator=(const ssl_domain&); + PN_CPP_EXTERN ~ssl_domain(); + + ssl_options_impl* impl_; +}; + +ssl_domain::ssl_domain(const ssl_domain& x): impl_(x.impl_) { if (impl_) impl_->incref(); } +ssl_domain& ssl_domain::operator=(const ssl_domain& x) { + if (&x != this) { + if (impl_) impl_->decref(); + impl_ = x.impl_; + if (impl_) impl_->incref(); + } + return *this; +} +ssl_domain::~ssl_domain() { if (impl_) impl_->decref(); } +}} + // These are a bit harder because they can't be publicly in the classes anymore so just use alias definitions // but that needs the mangled symbol names unfortunately. // @@ -164,7 +195,6 @@ ssl_certificate::ssl_certificate(const std::string &main, const std::string &ext // enum ssl::verify_mode = ssl::VERIFY_PEER_NAME); extern "C" { -#pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wpragmas" #pragma GCC diagnostic ignored "-Wunknown-warning-option" #pragma GCC diagnostic ignored "-Wattribute-alias" @@ -194,38 +224,6 @@ __attribute__((alias("_ZN6proton18ssl_client_optionsC1ERKNS_15ssl_certificateERK PN_CPP_EXTERN void _ZN6proton18ssl_client_optionsC2ERNS_15ssl_certificateERKSsNS_3ssl11verify_modeE() __attribute__((alias("_ZN6proton18ssl_client_optionsC2ERKNS_15ssl_certificateERKSsNS_3ssl11verify_modeE"))); #endif -#pragma GCC diagnostic pop } -// -// These are a bit easier as the entire class has been removed so we can just define the class here -// They do rely on the impl_ member being effectively the same type and structure location from -// The previous parent type ssl_domain to ssl_server_options/ssl_client_options. -// -// PN_CPP_EXTERN proton::internal::ssl_domain::ssl_domain(const ssl_domain&); -// PN_CPP_EXTERN proton::internal::ssl_domain::ssl_domain& operator=(const ssl_domain&); -// PN_CPP_EXTERN proton::internal::ssl_domain::~ssl_domain(); -// -namespace proton { -namespace internal { -class ssl_domain { - PN_CPP_EXTERN ssl_domain(const ssl_domain&); - PN_CPP_EXTERN ssl_domain& operator=(const ssl_domain&); - PN_CPP_EXTERN ~ssl_domain(); - - ssl_options_impl* impl_; -}; - -ssl_domain::ssl_domain(const ssl_domain& x): impl_(x.impl_) { if (impl_) impl_->incref(); } -ssl_domain& ssl_domain::operator=(const ssl_domain& x) { - if (&x != this) { - if (impl_) impl_->decref(); - impl_ = x.impl_; - if (impl_) impl_->incref(); - } - return *this; -} -ssl_domain::~ssl_domain() { if (impl_) impl_->decref(); } -}} - #endif --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@qpid.apache.org For additional commands, e-mail: commits-h...@qpid.apache.org