From: Markus Armbruster Date: Fri, 23 May 2014 11:24:39 +0000 (+0200) Subject: libcacard/vcard_emul_nss: Drop a redundant conditional X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=42119fa3568dc7e8c82447c861678a5987d06d91;p=qemu.git libcacard/vcard_emul_nss: Drop a redundant conditional Bailing out when PK11_FindGenericObjects() returns null ensures the loop that follows it executes at least once. The "loop did not execute" test right after it is useless. Drop it. Spotted by Coverity. Signed-off-by: Markus Armbruster Reviewed-by: Alon Levy Signed-off-by: Michael Tokarev --- diff --git a/libcacard/vcard_emul_nss.c b/libcacard/vcard_emul_nss.c index 8e055517f8..b7db51df34 100644 --- a/libcacard/vcard_emul_nss.c +++ b/libcacard/vcard_emul_nss.c @@ -618,11 +618,6 @@ vcard_emul_mirror_card(VReader *vreader) cert_count++; } - if (cert_count == 0) { - PK11_DestroyGenericObjects(firstObj); - return NULL; - } - /* allocate the arrays */ vcard_emul_alloc_arrays(&certs, &cert_len, &keys, cert_count);