diff options
author | John Baldwin <jhb@FreeBSD.org> | 2020-03-05 11:26:06 -0800 |
---|---|---|
committer | Matt Caswell <matt@openssl.org> | 2020-08-31 09:34:19 +0100 |
commit | 3c1641e8e86dc86028637251421a57827243f6ca (patch) | |
tree | 04bad79ea04a1c9837d5a5601e48b1dcaa3bb27b | |
parent | 0a90a90c4626dab3b6931e6a1e0bba9419720146 (diff) | |
download | openssl-3c1641e8e86dc86028637251421a57827243f6ca.zip openssl-3c1641e8e86dc86028637251421a57827243f6ca.tar.gz openssl-3c1641e8e86dc86028637251421a57827243f6ca.tar.bz2 |
Don't check errno if ktls_read_record() returned 0.
errno is only valid if ktls_read_record() fails with a negative return
value.
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/12111)
-rw-r--r-- | ssl/record/ssl3_record.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/ssl/record/ssl3_record.c b/ssl/record/ssl3_record.c index 27167ba..634052d 100644 --- a/ssl/record/ssl3_record.c +++ b/ssl/record/ssl3_record.c @@ -213,7 +213,7 @@ int ssl3_get_record(SSL *s) num_recs == 0 ? 1 : 0, &n); if (rret <= 0) { #ifndef OPENSSL_NO_KTLS - if (!BIO_get_ktls_recv(s->rbio)) + if (!BIO_get_ktls_recv(s->rbio) || rret == 0) return rret; /* error or non-blocking */ switch (errno) { case EBADMSG: |