diff options
author | Theo Buehler <tb@cvs.openbsd.org> | 2022-06-07 17:32:54 +0000 |
---|---|---|
committer | Theo Buehler <tb@cvs.openbsd.org> | 2022-06-07 17:32:54 +0000 |
commit | 57f4b63637b997ef4f5faddea51514598551f7ec (patch) | |
tree | f371aeb67bf686c92af8bb42441ea3cff6ae2f8b /lib/libssl/ssl_sess.c | |
parent | 80db7a56e3d660decc9cb3c2fa5380abc98194c7 (diff) |
Tweak readability of a test: compare tmp explicitly against 0 and drop
redundant parentheses.
ok jsing
Diffstat (limited to 'lib/libssl/ssl_sess.c')
-rw-r--r-- | lib/libssl/ssl_sess.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libssl/ssl_sess.c b/lib/libssl/ssl_sess.c index af1fd3c8bfa..969371b1de3 100644 --- a/lib/libssl/ssl_sess.c +++ b/lib/libssl/ssl_sess.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl_sess.c,v 1.113 2022/06/07 17:31:36 tb Exp $ */ +/* $OpenBSD: ssl_sess.c,v 1.114 2022/06/07 17:32:53 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -378,7 +378,7 @@ ssl_get_new_session(SSL *s, int session) * Don't allow the callback to set the session length to zero. * nor set it higher than it was. */ - if (!tmp || (tmp > ss->session_id_length)) { + if (tmp == 0 || tmp > ss->session_id_length) { /* The callback set an illegal length */ SSLerror(s, SSL_R_SSL_SESSION_ID_HAS_BAD_LENGTH); SSL_SESSION_free(ss); |