Add missing return in x509_ocsp_get_response()

Add missing return statement in x509_ocsp_get_response() that would
otherwise allow the code to continue executing even though a parsing
failure has already been found.
This commit is contained in:
Andres Amaya Garcia
2017-08-29 17:29:33 +01:00
committed by Andres Amaya Garcia
parent 03b02e3277
commit 7bdac59ad7

View File

@@ -924,6 +924,7 @@ static int x509_ocsp_get_response( mbedtls_x509_ocsp_response *resp,
*/
if( ( ret = mbedtls_asn1_get_tag( p, end, &len,
MBEDTLS_ASN1_CONSTRUCTED | MBEDTLS_ASN1_SEQUENCE ) ) != 0 )
return( MBEDTLS_ERR_X509_INVALID_FORMAT + ret );
end = *p + len;