diff options
author | NIIBE Yutaka <[email protected]> | 2013-03-26 03:43:24 +0000 |
---|---|---|
committer | NIIBE Yutaka <[email protected]> | 2013-03-26 03:49:03 +0000 |
commit | 64b1a2cf6f18348544a2d2cd4d49fd27bf01c150 (patch) | |
tree | 8a46eece2f620371c609d61a1d18024bdf0c482c /scd/apdu.c | |
parent | scd: PC/SC cleanup (more). (diff) | |
download | gnupg-64b1a2cf6f18348544a2d2cd4d49fd27bf01c150.tar.gz gnupg-64b1a2cf6f18348544a2d2cd4d49fd27bf01c150.zip |
scd: PC/SC status fix.
* scd/apdu.c (pcsc_get_status_direct): Check PCSC_STATE_MUTE only when
PCSC_STATE_PRESENT.
* scd/pcsc-wrapper.c (handle_status): Ditto.
Diffstat (limited to '')
-rw-r--r-- | scd/apdu.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/scd/apdu.c b/scd/apdu.c index 87c04266d..92c9864a0 100644 --- a/scd/apdu.c +++ b/scd/apdu.c @@ -891,9 +891,11 @@ pcsc_get_status_direct (int slot, unsigned int *status) *status = 0; if ( (rdrstates[0].event_state & PCSC_STATE_PRESENT) ) - *status |= APDU_CARD_PRESENT; - if ( !(rdrstates[0].event_state & PCSC_STATE_MUTE) ) - *status |= APDU_CARD_ACTIVE; + { + *status |= APDU_CARD_PRESENT; + if ( !(rdrstates[0].event_state & PCSC_STATE_MUTE) ) + *status |= APDU_CARD_ACTIVE; + } #ifndef HAVE_W32_SYSTEM /* We indicate a useful card if it is not in use by another application. This is because we only use exclusive access |