aboutsummaryrefslogtreecommitdiffstats
path: root/scd/apdu.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2003-07-29 08:53:19 +0000
committerWerner Koch <[email protected]>2003-07-29 08:53:19 +0000
commit97d3ea897fb66b15f2b20251a2e856e529c1b55e (patch)
treee7b2c80814861bf41256c9c93616917b6642728e /scd/apdu.c
parentAdjusted for use with current libgcrypt (1.1.42). (diff)
downloadgnupg-97d3ea897fb66b15f2b20251a2e856e529c1b55e.tar.gz
gnupg-97d3ea897fb66b15f2b20251a2e856e529c1b55e.zip
* gpgsm.c (main): Add secmem features and set the random seed file.
(gpgsm_exit): Update the random seed file and enable debug output. * g10.c (main): Add secmem features and set the random seed file. (g10_exit): Update the random seed file. * parse-packet.c (parse_signature,read_protected_v3_mpi) (parse_key): Fixed use of mpi_set_opaque. * keygen.c (gen_card_key): Ditto.
Diffstat (limited to '')
-rw-r--r--scd/apdu.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/scd/apdu.c b/scd/apdu.c
index 773225415..6fec584b9 100644
--- a/scd/apdu.c
+++ b/scd/apdu.c
@@ -32,8 +32,8 @@
#define HAVE_CTAPI 1
#define MAX_READER 4 /* Number of readers we support concurrently. */
-#define CARD_CONNECT_TIMEOUT 30 /* Number of seconds to wait for
- insertion of the card. */
+#define CARD_CONNECT_TIMEOUT 1 /* Number of seconds to wait for
+ insertion of the card (1 = don't wait). */
@@ -149,6 +149,9 @@ ct_activate_card (int reader)
unsigned char dad[1], sad[1], cmd[11], buf[256];
unsigned short buflen;
+ if (count)
+ sleep (1); /* FIXME: we should use a more reliable timer. */
+
/* Check whether card has been inserted. */
dad[0] = 1; /* Destination address: CT. */
sad[0] = 2; /* Source address: Host. */
@@ -203,7 +206,6 @@ ct_activate_card (int reader)
return 0;
}
- sleep (1); /* FIXME: we should use a more reliable timer. */
}
log_info ("ct_activate_card(%d): timeout waiting for card\n", reader);