Update fix to be more platform-independent
Co-authored-by: David Horstmann <david.horstmann@arm.com> Signed-off-by: Jonathan Winzig <jwinzig@hilscher.com>
This commit is contained in:
parent
05c722bfd0
commit
5caf20ea80
1 changed files with 1 additions and 1 deletions
|
@ -382,7 +382,7 @@ int mbedtls_x509_set_extension(mbedtls_asn1_named_data **head, const char *oid,
|
|||
{
|
||||
mbedtls_asn1_named_data *cur;
|
||||
|
||||
if (0xFFFFFFFF == (uint32_t) val_len) {
|
||||
if (val_len > (SIZE_MAX - 1)) {
|
||||
return MBEDTLS_ERR_X509_BAD_INPUT_DATA;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue