[Pcsclite-git-commit] [CCID] 03/05: IFDHTransmitToICC: Reuse ccid_descriptor

Ludovic Rousseau rousseau at moszumanska.debian.org
Sun Nov 8 21:01:10 UTC 2015


This is an automated email from the git hooks/post-receive script.

rousseau pushed a commit to branch master
in repository CCID.

commit cda5ca7aeb1440bfd0215ee9d79cfe1f845b735c
Author: Ludovic Rousseau <ludovic.rousseau at free.fr>
Date:   Fri Nov 6 20:41:21 2015 +0100

    IFDHTransmitToICC: Reuse ccid_descriptor
    
    ccid_descriptor is now already computed. Reuse this value where
    possible.
---
 src/ifdhandler.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/ifdhandler.c b/src/ifdhandler.c
index ea70cb3..35f3fcb 100644
--- a/src/ifdhandler.c
+++ b/src/ifdhandler.c
@@ -1288,7 +1288,7 @@ EXTERNAL RESPONSECODE IFDHTransmitToICC(DWORD Lun, SCARD_IO_HEADER SendPci,
 		Lun);
 
 	/* special APDU for the Kobil IDToken (CLASS = 0xFF) */
-	if (KOBIL_IDTOKEN == get_ccid_descriptor(reader_index) -> readerID)
+	if (KOBIL_IDTOKEN == ccid_descriptor -> readerID)
 	{
 		char manufacturer[] = {0xFF, 0x9A, 0x01, 0x01, 0x00};
 		char product_name[] = {0xFF, 0x9A, 0x01, 0x03, 0x00};
@@ -1316,7 +1316,7 @@ EXTERNAL RESPONSECODE IFDHTransmitToICC(DWORD Lun, SCARD_IO_HEADER SendPci,
 		if ((sizeof firmware_version == TxLength)
 			&& (memcmp(TxBuffer, firmware_version, sizeof firmware_version) == 0))
 		{
-			int IFD_bcdDevice = get_ccid_descriptor(reader_index)->IFD_bcdDevice;
+			int IFD_bcdDevice = ccid_descriptor -> IFD_bcdDevice;
 
 			DEBUG_INFO1("IDToken: Firmware version command");
 			*RxLength = sprintf((char *)RxBuffer, "%X.%02X",

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pcsclite/CCID.git



More information about the Pcsclite-cvs-commit mailing list