@@ -613,10 +613,11 @@ SCardDisconnect(cackey_slots[idx].pcsc_card, SCARD_LEAVE_CARD); } cackey_slots[idx].pcsc_card_connected = 0; + cackey_slots[idx].transaction_depth = 0; } CACKEY_DEBUG_PRINTF("Returning"); return; @@ -2286,10 +2287,11 @@ } for (idx = 0; idx < (sizeof(cackey_slots) / sizeof(cackey_slots[0])); idx++) { cackey_slots[idx].active = 0; cackey_slots[idx].pcsc_reader = NULL; + cackey_slots[idx].transaction_depth = 0; } cackey_initialized = 1; if (!cackey_biglock_init) { @@ -2474,10 +2476,11 @@ /* Only update the list of slots if we are actually being supply the slot information */ if (pSlotList) { cackey_slots[currslot].active = 1; cackey_slots[currslot].pcsc_reader = strdup(pcsc_readers); cackey_slots[currslot].pcsc_card_connected = 0; + cackey_slots[currslot].transaction_depth = 0; } currslot++; pcsc_readers += curr_reader_len + 1; }