diff options
author | Doug Hogan <doug@cvs.openbsd.org> | 2015-07-21 03:34:39 +0000 |
---|---|---|
committer | Doug Hogan <doug@cvs.openbsd.org> | 2015-07-21 03:34:39 +0000 |
commit | ea120dbf1e02417fc37804866f52374d86227aeb (patch) | |
tree | 59e7079cef815514ddf2a203b3729371db191d0f /lib/libssl | |
parent | 283c1eeb65434d234ca3201d94ee5a9cfc4a6cfa (diff) |
Remove duplicate check in libssl.
If len == 0, it already set try_session_cache so there's no need to
check len again. Fixes Coverity issue 21687.
ok bcook@
Diffstat (limited to 'lib/libssl')
-rw-r--r-- | lib/libssl/ssl_sess.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/lib/libssl/ssl_sess.c b/lib/libssl/ssl_sess.c index 80b883f7862..ef5b9be56d1 100644 --- a/lib/libssl/ssl_sess.c +++ b/lib/libssl/ssl_sess.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ssl_sess.c,v 1.44 2014/12/14 15:30:50 jsing Exp $ */ +/* $OpenBSD: ssl_sess.c,v 1.45 2015/07/21 03:34:38 doug Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -452,8 +452,6 @@ ssl_get_prev_session(SSL *s, unsigned char *session_id, int len, SSL_SESSION data; data.ssl_version = s->version; data.session_id_length = len; - if (len == 0) - return 0; memcpy(data.session_id, session_id, len); CRYPTO_r_lock(CRYPTO_LOCK_SSL_CTX); |