diff options
author | Werner Koch <[email protected]> | 2010-11-17 13:21:24 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2010-11-17 13:21:24 +0000 |
commit | 0103a53aa6dbd434e4b85c3176b6a4304ea0f040 (patch) | |
tree | c000f22ae692f47a1a20753677e4e8d0c9f712a9 /g10/misc.c | |
parent | Update FAQ (diff) | |
download | gnupg-0103a53aa6dbd434e4b85c3176b6a4304ea0f040.tar.gz gnupg-0103a53aa6dbd434e4b85c3176b6a4304ea0f040.zip |
Smartcard related updates
Diffstat (limited to '')
-rw-r--r-- | g10/misc.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/g10/misc.c b/g10/misc.c index cbbba9bc3..b3b73ed67 100644 --- a/g10/misc.c +++ b/g10/misc.c @@ -548,13 +548,12 @@ static unsigned long get_signature_count (PKT_public_key *pk) { #ifdef ENABLE_CARD_SUPPORT - /* FIXME: Need to call the agent. */ - /* if(sk && sk->is_protected && sk->protect.s2k.mode==1002) */ - /* { */ - /* struct agent_card_info_s info; */ - /* if(agent_scd_getattr("SIG-COUNTER",&info)==0) */ - /* return info.sig_counter; */ - /* } */ + struct agent_card_info_s info; +#warning fixme: We should check that the correct card has been inserted + if (!agent_scd_getattr ("SIG-COUNTER",&info)) + return info.sig_counter; + else + return 0; #else (void)pk; return 0; |