@@ -227,10 +227,17 @@ chk_rv = C_GetSlotList(FALSE, slots, &numSlots); if (chk_rv != CKR_OK) { return(1); } + + currSlot = 0; + printf("Please insert a card now.\n"); + chk_rv = C_WaitForSlotEvent(0, &currSlot, NULL); + if (chk_rv != CKR_OK) { + printf("Failed to wait for slot event.\n"); + } for (currSlot = 0; currSlot < numSlots; currSlot++) { printf(" Slot %lu:\n", currSlot); chk_rv = C_GetSlotInfo(slots[currSlot], &slotInfo);