mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-02 22:46:30 +02:00
(apdu_open_reader): No fallback if a full CCID reader id has been
Removed test code from ccid-driver.c
This commit is contained in:
parent
f08c4222b7
commit
ca26884b3a
3 changed files with 21 additions and 238 deletions
10
g10/apdu.c
10
g10/apdu.c
|
@ -1879,11 +1879,19 @@ apdu_open_reader (const char *portstr)
|
|||
#ifdef HAVE_LIBUSB
|
||||
if (!opt.disable_ccid)
|
||||
{
|
||||
int slot;
|
||||
int slot, i;
|
||||
const char *s;
|
||||
|
||||
slot = open_ccid_reader (portstr);
|
||||
if (slot != -1)
|
||||
return slot; /* got one */
|
||||
|
||||
/* If a CCID reader specification has been given, the user does
|
||||
not want a fallback to other drivers. */
|
||||
if (portstr)
|
||||
for (s=portstr, i=0; *s; s++)
|
||||
if (*s == ':' && (++i == 3))
|
||||
return -1;
|
||||
}
|
||||
|
||||
#endif /* HAVE_LIBUSB */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue