Tidy up some warnings.
Updating clang seems to have upset the clang-cl build. I think because they decided -Wall now matches MSVC's semantics, which is a little nuts. Two of the warnings, however, weren't wrong, so fix those. http://llvm.org/viewvc/llvm-project?view=revision&revision=319116 Change-Id: I168e52e4e70ca7b1069e0b0db241fb5305c12b1e Reviewed-on: https://boringssl-review.googlesource.com/24684 Reviewed-by: Steven Valdez <svaldez@google.com> Commit-Queue: David Benjamin <davidben@google.com> CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
This commit is contained in:
parent
e2b8466fa7
commit
53ff70f68c
@ -228,9 +228,10 @@ extern "C" {
|
|||||||
#define OPENSSL_FALLTHROUGH [[fallthrough]]
|
#define OPENSSL_FALLTHROUGH [[fallthrough]]
|
||||||
#elif defined(__cplusplus) && __cplusplus >= 201103L && defined(__clang__)
|
#elif defined(__cplusplus) && __cplusplus >= 201103L && defined(__clang__)
|
||||||
#define OPENSSL_FALLTHROUGH [[clang::fallthrough]]
|
#define OPENSSL_FALLTHROUGH [[clang::fallthrough]]
|
||||||
#elif defined(__cplusplus) && __cplusplus >= 201103L && __GNUC__ >= 7
|
#elif defined(__cplusplus) && __cplusplus >= 201103L && defined(__GNUC__) && \
|
||||||
|
__GNUC__ >= 7
|
||||||
#define OPENSSL_FALLTHROUGH [[gnu::fallthrough]]
|
#define OPENSSL_FALLTHROUGH [[gnu::fallthrough]]
|
||||||
#elif __GNUC__ >= 7 // gcc 7
|
#elif defined(__GNUC__) && __GNUC__ >= 7 // gcc 7
|
||||||
#define OPENSSL_FALLTHROUGH __attribute__ ((fallthrough))
|
#define OPENSSL_FALLTHROUGH __attribute__ ((fallthrough))
|
||||||
#else // C++11 on gcc 6, and all other cases
|
#else // C++11 on gcc 6, and all other cases
|
||||||
#define OPENSSL_FALLTHROUGH
|
#define OPENSSL_FALLTHROUGH
|
||||||
|
@ -344,7 +344,7 @@ struct StackTraits {};
|
|||||||
sk_##name##_deep_copy(const STACK_OF(name) *sk, \
|
sk_##name##_deep_copy(const STACK_OF(name) *sk, \
|
||||||
ptrtype(*copy_func)(ptrtype), \
|
ptrtype(*copy_func)(ptrtype), \
|
||||||
void (*free_func)(ptrtype)) { \
|
void (*free_func)(ptrtype)) { \
|
||||||
return (STACK_OF(name) *)sk_deep_copy((_STACK *)sk, \
|
return (STACK_OF(name) *)sk_deep_copy((const _STACK *)sk, \
|
||||||
(void *(*)(void *))copy_func, \
|
(void *(*)(void *))copy_func, \
|
||||||
(void (*)(void *))free_func); \
|
(void (*)(void *))free_func); \
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user