diff options
author | Francis Dupont <fdupont@isc.org> | 2017-12-21 16:29:24 +0100 |
---|---|---|
committer | Francis Dupont <fdupont@isc.org> | 2017-12-21 16:29:24 +0100 |
commit | 851dc7125671a0ccf15ff619d9acf59880305510 (patch) | |
tree | 61265d69e3130e2efa9af1d0c6020c129e8b1892 | |
parent | [5449] Fixes from address sanitizer run on last macOS/Xcode (diff) | |
download | kea-851dc7125671a0ccf15ff619d9acf59880305510.tar.xz kea-851dc7125671a0ccf15ff619d9acf59880305510.zip |
[5449] Spit has_feature #if
-rw-r--r-- | src/lib/cryptolink/openssl_common.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/lib/cryptolink/openssl_common.h b/src/lib/cryptolink/openssl_common.h index 6011f7e6c8..7e47e698f5 100644 --- a/src/lib/cryptolink/openssl_common.h +++ b/src/lib/cryptolink/openssl_common.h @@ -37,10 +37,12 @@ public: SecBuf(const std::vector<T>& x) : vec_(x) {} ~SecBuf() { -#if defined(__has_feature) && __has_feature(address_sanitizer) +#if defined(__has_feature) +#if __has_feature(address_sanitizer) // Make the address sanitizer happy assuming this won't reallocate vec_.resize(vec_.capacity()); #endif +#endif std::memset(&vec_[0], 0, vec_.capacity() * sizeof(T)); }; @@ -69,10 +71,12 @@ public: }; void clear() { -#if defined(__has_feature) && __has_feature(address_sanitizer) +#if defined(__has_feature) +#if __has_feature(address_sanitizer) // Make the address sanitizer happy assuming this won't reallocate vec_.resize(vec_.capacity()); #endif +#endif std::memset(&vec_[0], 0, vec_.capacity() * sizeof(T)); vec_.clear(); } |