1
0
mirror of https://github.com/Mbed-TLS/mbedtls.git synced 2025-07-29 11:41:15 +03:00

Make malloc-init script a bit happier

This commit is contained in:
Manuel Pégourié-Gonnard
2014-11-12 22:27:42 +01:00
parent 5924f9f810
commit e5b0fc1847
5 changed files with 15 additions and 18 deletions

View File

@ -327,6 +327,8 @@ asn1_named_data *asn1_store_named_data( asn1_named_data **head,
return( NULL );
}
memcpy( cur->oid.p, oid, oid_len );
cur->val.len = val_len;
cur->val.p = polarssl_malloc( val_len );
if( cur->val.p == NULL )
@ -336,8 +338,6 @@ asn1_named_data *asn1_store_named_data( asn1_named_data **head,
return( NULL );
}
memcpy( cur->oid.p, oid, oid_len );
cur->next = *head;
*head = cur;
}