summaryrefslogtreecommitdiff
path: root/plugins/smartcard/gsd-smartcard-manager.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/smartcard/gsd-smartcard-manager.c')
-rw-r--r--plugins/smartcard/gsd-smartcard-manager.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugins/smartcard/gsd-smartcard-manager.c b/plugins/smartcard/gsd-smartcard-manager.c
index acd22df8..a219e22e 100644
--- a/plugins/smartcard/gsd-smartcard-manager.c
+++ b/plugins/smartcard/gsd-smartcard-manager.c
@@ -212,7 +212,12 @@ watch_one_event_from_driver (GsdSmartcardManager *self,
error_code = PORT_GetError ();
if (error_code == SEC_ERROR_NO_EVENT) {
- g_usleep (1 * G_USEC_PER_SEC);
+ int old_slot_count = operation->driver->slotCount;
+ SECMOD_UpdateSlotList (operation->driver);
+ if (operation->driver->slotCount != old_slot_count)
+ g_debug ("Slot count change %i -> %i", old_slot_count, operation->driver->slotCount);
+ else
+ g_usleep (1 * G_USEC_PER_SEC);
return TRUE;
}