[Pcsclite-cvs-commit] r1680 - trunk/PCSC/src

Ludovic Rousseau rousseau at costa.debian.org
Wed Sep 28 08:06:09 UTC 2005


Author: rousseau
Date: 2005-09-28 08:06:09 +0000 (Wed, 28 Sep 2005)
New Revision: 1680

Modified:
   trunk/PCSC/src/eventhandler.c
Log:
EHStatusHandlerThread(): Solaris 10 IFDhandler expect to have
CardAtrLength set to a sensible value. So add an initialisation before
calling IFDPowerICC()

Thanks to Douglas E. Engert for the patch


Modified: trunk/PCSC/src/eventhandler.c
===================================================================
--- trunk/PCSC/src/eventhandler.c	2005-09-28 08:02:23 UTC (rev 1679)
+++ trunk/PCSC/src/eventhandler.c	2005-09-28 08:06:09 UTC (rev 1680)
@@ -222,6 +222,7 @@
 			&rContext->readerState->cardAtrLength);
 	if (dwStatus & SCARD_PRESENT)
 	{
+		rContext->readerState->cardAtrLength = MAX_ATR_SIZE;
 		rv = IFDPowerICC(rContext, IFD_POWER_UP,
 			rContext->readerState->cardAtr,
 			&rContext->readerState->cardAtrLength);
@@ -375,6 +376,7 @@
 				 * Power and reset the card 
 				 */
 				SYS_USleep(PCSCLITE_STATUS_WAIT);
+				rContext->readerState->cardAtrLength = MAX_ATR_SIZE;
 				rv = IFDPowerICC(rContext, IFD_POWER_UP,
 					rContext->readerState->cardAtr,
 					&rContext->readerState->cardAtrLength);




More information about the Pcsclite-cvs-commit mailing list