mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-01-03 23:43:40 +00:00
pkarse: Update pk_group_id_from_specified()
clean-up.
This path updates the clean-up logic of to individually free each of the the group's structure members rather than invoke `mbedtls_ecp_group_free()`. Signed-off-by: Minos Galanakis <minos.galanakis@arm.com>
This commit is contained in:
parent
e9fa7a74cd
commit
c8e381ab1c
@ -429,7 +429,11 @@ static int pk_group_id_from_specified(const mbedtls_asn1_buf *params,
|
||||
ret = pk_group_id_from_group(&grp, grp_id);
|
||||
|
||||
cleanup:
|
||||
mbedtls_ecp_group_free(&grp);
|
||||
mbedtls_mpi_free(&grp.N);
|
||||
mbedtls_mpi_free(&grp.P);
|
||||
mbedtls_mpi_free(&grp.A);
|
||||
mbedtls_mpi_free(&grp.B);
|
||||
mbedtls_ecp_point_free(&grp.G);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user