[Pcsclite-cvs-commit] r1641 - trunk/Drivers/ccid/src

Ludovic Rousseau rousseau at costa.debian.org
Mon Sep 5 14:43:02 UTC 2005


Author: rousseau
Date: 2005-09-05 14:43:02 +0000 (Mon, 05 Sep 2005)
New Revision: 1641

Modified:
   trunk/Drivers/ccid/src/ccid_usb.c
Log:
get_data_rates(): check the response size only if bNumDataRatesSupported
is non zero


Modified: trunk/Drivers/ccid/src/ccid_usb.c
===================================================================
--- trunk/Drivers/ccid/src/ccid_usb.c	2005-09-05 14:40:13 UTC (rev 1640)
+++ trunk/Drivers/ccid/src/ccid_usb.c	2005-09-05 14:43:02 UTC (rev 1641)
@@ -742,7 +742,7 @@
 	/* we do not get the expected number of data rates */
 	len = get_ccid_usb_interface(usbDevice[reader_index].dev)
 		->altsetting->extra[27]; /* bNumDataRatesSupported */
-	if (n != len)
+	if ((n != len) && len)
 	{
 		DEBUG_INFO3("Got %d data rates but was expecting %d", n, len);
 




More information about the Pcsclite-cvs-commit mailing list