mirror of
https://github.com/Mbed-TLS/mbedtls.git
synced 2025-02-28 09:39:53 +00:00
Move num ops update to only point where work can be done.
Signed-off-by: Paul Elliott <paul.elliott@arm.com>
This commit is contained in:
parent
53bb312054
commit
ebe225cf7b
@ -3287,11 +3287,12 @@ psa_status_t psa_sign_hash_complete(
|
||||
status = psa_driver_wrapper_sign_hash_complete(operation, signature,
|
||||
signature_size,
|
||||
signature_length);
|
||||
exit:
|
||||
|
||||
/* Update ops count with work done. */
|
||||
operation->num_ops = psa_driver_wrapper_sign_hash_get_num_ops(operation);
|
||||
|
||||
exit:
|
||||
|
||||
psa_wipe_output_buffer(signature, status, signature_size,
|
||||
*signature_length);
|
||||
|
||||
@ -3418,12 +3419,12 @@ psa_status_t psa_verify_hash_complete(
|
||||
|
||||
status = psa_driver_wrapper_verify_hash_complete(operation);
|
||||
|
||||
exit:
|
||||
|
||||
/* Update ops count with work done. */
|
||||
operation->num_ops = psa_driver_wrapper_verify_hash_get_num_ops(
|
||||
operation);
|
||||
|
||||
exit:
|
||||
|
||||
if (status != PSA_OPERATION_INCOMPLETE) {
|
||||
if (status != PSA_SUCCESS) {
|
||||
operation->error_occurred = 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user