Skip to content
Snippets Groups Projects
Commit 27720691 authored by Tatsuhiro Tsujikawa's avatar Tatsuhiro Tsujikawa
Browse files

Fix 'overlapping comparisons always evaluate to true' compile error with clang-10

parent 42528792
No related merge requests found
...@@ -70,12 +70,12 @@ ngtcp2_crypto_ctx *ngtcp2_crypto_ctx_tls(ngtcp2_crypto_ctx *ctx, ...@@ -70,12 +70,12 @@ ngtcp2_crypto_ctx *ngtcp2_crypto_ctx_tls(ngtcp2_crypto_ctx *ctx,
gnutls_cipher_algorithm_t hp_cipher; gnutls_cipher_algorithm_t hp_cipher;
cipher = gnutls_cipher_get(session); cipher = gnutls_cipher_get(session);
if (cipher != GNUTLS_CIPHER_UNKNOWN || cipher != GNUTLS_CIPHER_NULL) { if (cipher != GNUTLS_CIPHER_UNKNOWN && cipher != GNUTLS_CIPHER_NULL) {
ctx->aead.native_handle = (void *)cipher; ctx->aead.native_handle = (void *)cipher;
} }
hash = gnutls_prf_hash_get(session); hash = gnutls_prf_hash_get(session);
if (hash != GNUTLS_DIG_UNKNOWN || hash != GNUTLS_DIG_NULL) { if (hash != GNUTLS_DIG_UNKNOWN && hash != GNUTLS_DIG_NULL) {
ctx->md.native_handle = (void *)hash; ctx->md.native_handle = (void *)hash;
} }
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment