diff options
author | wtc%netscape.com <devnull@localhost> | 2002-05-10 23:10:06 +0000 |
---|---|---|
committer | wtc%netscape.com <devnull@localhost> | 2002-05-10 23:10:06 +0000 |
commit | 267d20daa2aa5b2c1aae1c85be0737a32ac723c6 (patch) | |
tree | 96ead0e7a9406a9e9321ea2a2e8a4b9b80fa31c3 | |
parent | 792bd600b2431650a2892ab4b81ac3c7be968270 (diff) | |
download | nss-hg-267d20daa2aa5b2c1aae1c85be0737a32ac723c6.tar.gz |
Bugzilla bug 135052: more cleanup in SEC_PKCS12DecoderStart. r=relyea.
-rw-r--r-- | security/nss/lib/pkcs12/p12d.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/security/nss/lib/pkcs12/p12d.c b/security/nss/lib/pkcs12/p12d.c index 0f0b1e671..93a7ff200 100644 --- a/security/nss/lib/pkcs12/p12d.c +++ b/security/nss/lib/pkcs12/p12d.c @@ -1202,12 +1202,6 @@ SEC_PKCS12DecoderStart(SECItem *pwitem, PK11SlotInfo *slot, void *wincx, p12dcx->errorValue = 0; p12dcx->error = PR_FALSE; - /* a slot is *required */ - if(!slot) { - PORT_SetError(SEC_ERROR_NO_MEMORY); - goto loser; - } - /* start the decoding of the PFX and set the notify proc * for the PFX item. */ @@ -1215,6 +1209,7 @@ SEC_PKCS12DecoderStart(SECItem *pwitem, PK11SlotInfo *slot, void *wincx, sec_PKCS12PFXItemTemplate); if(!p12dcx->pfxDcx) { PORT_SetError(SEC_ERROR_NO_MEMORY); + PK11_FreeSlot(p12dcx->slot); goto loser; } |