From 56a26ce3600cc9f96da0e64b345a25276d9abfc0 Mon Sep 17 00:00:00 2001 From: Matt Caswell Date: Wed, 19 Oct 2016 16:28:12 +0100 Subject: [PATCH] Now that we can use size_t in PACKET lets use it Reviewed-by: Rich Salz --- ssl/statem/statem_clnt.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/ssl/statem/statem_clnt.c b/ssl/statem/statem_clnt.c index bde5373fe7..d8fbf582e6 100644 --- a/ssl/statem/statem_clnt.c +++ b/ssl/statem/statem_clnt.c @@ -1973,7 +1973,6 @@ MSG_PROCESS_RETURN tls_process_new_session_ticket(SSL *s, PACKET *pkt) MSG_PROCESS_RETURN tls_process_cert_status(SSL *s, PACKET *pkt) { int al; - unsigned long resplenl; size_t resplen; unsigned int type; @@ -1983,13 +1982,12 @@ MSG_PROCESS_RETURN tls_process_cert_status(SSL *s, PACKET *pkt) SSLerr(SSL_F_TLS_PROCESS_CERT_STATUS, SSL_R_UNSUPPORTED_STATUS_TYPE); goto f_err; } - if (!PACKET_get_net_3(pkt, &resplenl) - || PACKET_remaining(pkt) != resplenl) { + if (!PACKET_get_net_3_len(pkt, &resplen) + || PACKET_remaining(pkt) != resplen) { al = SSL_AD_DECODE_ERROR; SSLerr(SSL_F_TLS_PROCESS_CERT_STATUS, SSL_R_LENGTH_MISMATCH); goto f_err; } - resplen = resplenl; s->tlsext_ocsp_resp = OPENSSL_malloc(resplen); if (s->tlsext_ocsp_resp == NULL) { al = SSL_AD_INTERNAL_ERROR; -- GitLab