Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
align comment with implementation order
  • Loading branch information
frankmorgner committed Feb 20, 2020
1 parent 31d8c2d commit 8f4a6c7
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/pkcs11/pkcs11-global.c
Expand Up @@ -469,8 +469,8 @@ CK_RV C_GetSlotList(CK_BBOOL tokenPresent, /* only slots with token prese
slot = (sc_pkcs11_slot_t *) list_get_at(&virtual_slots, i);
/* the list of available slots contains:
* - if present, virtual hotplug slot;
* - any slot with token;
* - without token(s), one empty slot per reader;
* - any slot with token;
* - any slot that has already been seen;
*/
if ((!tokenPresent && !slot->reader)
Expand Down Expand Up @@ -504,10 +504,7 @@ CK_RV C_GetSlotList(CK_BBOOL tokenPresent, /* only slots with token prese
sc_log(context, "returned %lu slots\n", numMatches);

out:
if (found != NULL) {
free (found);
found = NULL;
}
free (found);
sc_pkcs11_unlock();
return rv;
}
Expand Down

0 comments on commit 8f4a6c7

Please sign in to comment.