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 /ssl/record | |
parent | 0a90a90c4626dab3b6931e6a1e0bba9419720146 (diff) | |
download | openssl-new-3c1641e8e86dc86028637251421a57827243f6ca.tar.gz |
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)
Diffstat (limited to 'ssl/record')
-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 27167ba92f..634052d342 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: |