From 8feb62dbd0df2d8424f9935a0fceec65df7c261c Mon Sep 17 00:00:00 2001 From: "alexei.volkov.bugs%sun.com" Date: Sat, 22 Apr 2006 00:55:29 +0000 Subject: [PATCH] [Bug 334236] double free in PK11_ListPrivKeysInSlot if keys allocation fails. r=nelson --- security/nss/lib/pk11wrap/pk11akey.c | 1 + 1 file changed, 1 insertion(+) diff --git a/security/nss/lib/pk11wrap/pk11akey.c b/security/nss/lib/pk11wrap/pk11akey.c index 92a08660915c..04336d7a05f5 100644 --- a/security/nss/lib/pk11wrap/pk11akey.c +++ b/security/nss/lib/pk11wrap/pk11akey.c @@ -2013,6 +2013,7 @@ PK11_ListPrivKeysInSlot(PK11SlotInfo *slot, char *nickname, void *wincx) keys = SECKEY_NewPrivateKeyList(); if (keys == NULL) { PORT_Free(key_ids); + return NULL; } for (i=0; i < objCount ; i++) {