summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortb <>2021-06-28 18:42:17 +0000
committertb <>2021-06-28 18:42:17 +0000
commit456413aabbeb5f80eeb0dcaaa4512fb49344cbe0 (patch)
tree8ef6e1c3eed16a64ab44627cc166913366b1bf13 /src
parentae04ae2ebac1029c925e431a99bae7f6e4ab2900 (diff)
downloadopenbsd-456413aabbeb5f80eeb0dcaaa4512fb49344cbe0.tar.gz
openbsd-456413aabbeb5f80eeb0dcaaa4512fb49344cbe0.tar.bz2
openbsd-456413aabbeb5f80eeb0dcaaa4512fb49344cbe0.zip
ctx->alert is not a boolean, so compare it explicitly against 0.
Diffstat (limited to 'src')
-rw-r--r--src/lib/libssl/tls13_handshake.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/libssl/tls13_handshake.c b/src/lib/libssl/tls13_handshake.c
index 578cea338f..4e4a9101d0 100644
--- a/src/lib/libssl/tls13_handshake.c
+++ b/src/lib/libssl/tls13_handshake.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: tls13_handshake.c,v 1.66 2021/06/28 15:35:14 tb Exp $ */ 1/* $OpenBSD: tls13_handshake.c,v 1.67 2021/06/28 18:42:17 tb Exp $ */
2/* 2/*
3 * Copyright (c) 2018-2019 Theo Buehler <tb@openbsd.org> 3 * Copyright (c) 2018-2019 Theo Buehler <tb@openbsd.org>
4 * Copyright (c) 2019 Joel Sing <jsing@openbsd.org> 4 * Copyright (c) 2019 Joel Sing <jsing@openbsd.org>
@@ -383,7 +383,7 @@ tls13_handshake_perform(struct tls13_ctx *ctx)
383 (action->sender == ctx->mode) ? "sending" : "receiving", 383 (action->sender == ctx->mode) ? "sending" : "receiving",
384 tls13_handshake_message_name(action->handshake_type)); 384 tls13_handshake_message_name(action->handshake_type));
385 385
386 if (ctx->alert) 386 if (ctx->alert != 0)
387 return tls13_send_alert(ctx->rl, ctx->alert); 387 return tls13_send_alert(ctx->rl, ctx->alert);
388 388
389 if (action->sender == ctx->mode) 389 if (action->sender == ctx->mode)
@@ -391,7 +391,7 @@ tls13_handshake_perform(struct tls13_ctx *ctx)
391 else 391 else
392 ret = tls13_handshake_recv_action(ctx, action); 392 ret = tls13_handshake_recv_action(ctx, action);
393 393
394 if (ctx->alert) 394 if (ctx->alert != 0)
395 return tls13_send_alert(ctx->rl, ctx->alert); 395 return tls13_send_alert(ctx->rl, ctx->alert);
396 396
397 if (ret <= 0) { 397 if (ret <= 0) {