mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-17 01:54:22 +00:00
Free keys after use
Change-Id: I16ba4420ffeb9aa439e0a09a1b34d2aba2e1eb6e Signed-off-by: Jimmy Brisson <jimmy.brisson@arm.com>
This commit is contained in:
parent
bea8019826
commit
1f111f12b5
1 changed files with 7 additions and 0 deletions
|
@ -581,6 +581,13 @@ int main(int argc, char *argv[])
|
|||
}
|
||||
}
|
||||
|
||||
/* If we got here, then we must have filled the key array completely.
|
||||
* We can then safely call free on all of the keys in the array
|
||||
*/
|
||||
for (i = 0; i < num_keys; i++) {
|
||||
EVP_PKEY_free(keys[i].key);
|
||||
}
|
||||
|
||||
#ifndef OPENSSL_NO_ENGINE
|
||||
ENGINE_cleanup();
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue