diff options
author | Hongbo Li <[email protected]> | 2021-06-04 14:30:35 +0800 |
---|---|---|
committer | Herbert Xu <[email protected]> | 2021-06-11 15:03:30 +0800 |
commit | 5cd259ca5d466f65ffd21e2e2fa00fb648a8c555 (patch) | |
tree | f68c657bb63dc0f6bd8617774eee800c82c7c3bd /scripts/gdb/linux/tasks.py | |
parent | 9039878ade5d7ec6ac8db299ab8e7d0d563e3447 (diff) |
crypto: sm2 - fix a memory leak in sm2
SM2 module alloc ec->Q in sm2_set_pub_key(), when doing alg test in
test_akcipher_one(), it will set public key for every test vector,
and don't free ec->Q. This will cause a memory leak.
This patch alloc ec->Q in sm2_ec_ctx_init().
Fixes: ea7ecb66440b ("crypto: sm2 - introduce OSCCA SM2 asymmetric cipher algorithm")
Signed-off-by: Hongbo Li <[email protected]>
Reviewed-by: Tianjia Zhang <[email protected]>
Signed-off-by: Herbert Xu <[email protected]>
Diffstat (limited to 'scripts/gdb/linux/tasks.py')
0 files changed, 0 insertions, 0 deletions