diff options
author | Martin Thomson <martin.thomson@gmail.com> | 2015-10-16 16:12:00 -0700 |
---|---|---|
committer | Martin Thomson <martin.thomson@gmail.com> | 2015-10-16 16:12:00 -0700 |
commit | c80dd66d034b3860795e5db12ed82d328e411030 (patch) | |
tree | 88e9ec5d293b74c6ea4d051c6b4a5d3ca27603e1 /lib/pkcs7 | |
parent | 754958e1f9729d88c04f8da68fdf304be227647d (diff) | |
download | nss-hg-c80dd66d034b3860795e5db12ed82d328e411030.tar.gz |
Bug 1026688 - [CID 1202865][CID 1202869] Possible leak of |ciphercx| in sec_PKCS7CreateEncryptObject and NSS_CMSCipherContext_StartEncrypt on failure, r=mt
Diffstat (limited to 'lib/pkcs7')
-rw-r--r-- | lib/pkcs7/p7local.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/pkcs7/p7local.c b/lib/pkcs7/p7local.c index 8c5e0bfa5..5e67a0eba 100644 --- a/lib/pkcs7/p7local.c +++ b/lib/pkcs7/p7local.c @@ -203,7 +203,8 @@ sec_PKCS7CreateEncryptObject (PLArenaPool *poolp, PK11SymKey *key, rv = PK11_ParamToAlgid(algtag,param,poolp,algid); if(rv != SECSuccess) { PORT_Free (result); - SECITEM_FreeItem(param,PR_TRUE); + SECITEM_FreeItem(param,PR_TRUE); + PK11_DestroyContext(ciphercx, PR_TRUE); return NULL; } } |