Reviewed-by: Rich Salz <rsalz@openssl.org>
Reviewed-by: Bernd Edlinger <bernd.edlinger@hotmail.de>
(Merged from https://github.com/openssl/openssl/pull/5799)
int hvers;
/* avoid overlapping with length at the end of buffer */
- if (msglen < (SSL_IS_DTLS(ssl) ? 13 : 5)) {
+ if (msglen < (size_t)(SSL_IS_DTLS(ssl) ?
+ DTLS1_RT_HEADER_LENGTH : SSL3_RT_HEADER_LENGTH)) {
BIO_puts(bio, write_p ? "Sent" : "Received");
ssl_print_hex(bio, 0, " too short message", msg, msglen);
break;