Allow to use more than one token
This is needed if the first is not usable
This commit is contained in:
@@ -931,11 +931,11 @@ p11_init(hx509_context context,
|
|||||||
|
|
||||||
for (i = 0; i < p->num_slots; i++) {
|
for (i = 0; i < p->num_slots; i++) {
|
||||||
ret = p11_init_slot(context, p, lock, slot_ids[i], i, &p->slot[i]);
|
ret = p11_init_slot(context, p, lock, slot_ids[i], i, &p->slot[i]);
|
||||||
if (ret)
|
if (!ret) {
|
||||||
break;
|
|
||||||
if (p->slot[i].flags & P11_TOKEN_PRESENT)
|
if (p->slot[i].flags & P11_TOKEN_PRESENT)
|
||||||
num_tokens++;
|
num_tokens++;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
free(slot_ids);
|
free(slot_ids);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto out;
|
goto out;
|
||||||
|
Reference in New Issue
Block a user