]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Collapse two identical if statements into a single body.
authorJohn Baldwin <jhb@FreeBSD.org>
Fri, 9 Oct 2020 22:12:53 +0000 (15:12 -0700)
committerBenjamin Kaduk <kaduk@mit.edu>
Sun, 29 Nov 2020 02:36:16 +0000 (18:36 -0800)
These two bodies should be grouped together anyway as the reason for
the call to BIO_flush() is to permit using BIO_set_ktls_ctrl_msg().

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Ben Kaduk <kaduk@mit.edu>
(Merged from https://github.com/openssl/openssl/pull/13090)

ssl/record/rec_layer_s3.c

index 9fadeba62da56bd1a0e61b736c80a373c7464fa5..17ee8bd483441e60bc9a685c091aae5ea3b8e3a9 100644 (file)
@@ -1189,10 +1189,6 @@ int ssl3_write_pending(SSL *s, int type, const unsigned char *buf, size_t len,
                 i = BIO_flush(s->wbio);
                 if (i <= 0)
                     return i;
-            }
-
-            if (BIO_get_ktls_send(s->wbio)
-                && type != SSL3_RT_APPLICATION_DATA) {
                 BIO_set_ktls_ctrl_msg(s->wbio, type);
             }
             /* TODO(size_t): Convert this call */