Remove ktls specific code from tls_setup_write_buffers
The KTLS code no longer calls this function so this is not necessary.
@@ -158,8 +158,8 @@ int tls_setup_write_buffer(OSSL_RECORD_LAYER *rl, size_t numwpipes,
thiswb->buf = NULL; /* force reallocation */
}
- if (thiswb->buf == NULL) {
- if (rl->bio == NULL || !BIO_get_ktls_send(rl->bio)) {
+ p = thiswb->buf;
+ if (p == NULL) {
p = OPENSSL_malloc(len);
if (p == NULL) {
if (rl->numwpipes < currpipe)
@@ -172,14 +172,11 @@ int tls_setup_write_buffer(OSSL_RECORD_LAYER *rl, size_t numwpipes,
RLAYERfatal(rl, SSL_AD_NO_ALERT, ERR_R_CRYPTO_LIB);
return 0;
}
- } else {
- p = NULL;
}
memset(thiswb, 0, sizeof(SSL3_BUFFER));
thiswb->buf = p;
thiswb->len = len;
}
- }
/* Free any previously allocated buffers that we are no longer using */
tls_release_write_buffer_int(rl, currpipe);
