Revision
96
Author
ludovic.rousseau@gmail.com
Date
2010-01-11 05:31:59 -0800 (Mon, 11 Jan 2010)

Log Message

fix compiler warning and possible bug
pcscdmonitor.cpp:1119: warning: 'isPCCard' is used uninitialized in this function
pcscdmonitor.cpp:1150: warning: 'vendorID' is used uninitialized in this function
pcscdmonitor.cpp:1150: warning: 'productID' is used uninitialized in this function

The variables are not initialized because the call to
getVendorAndProductID() is commented

Modified Paths

Diff

Modified: trunk/SmartCardServices/src/PCSC/pcscdmonitor.cpp (95 => 96)


--- trunk/SmartCardServices/src/PCSC/pcscdmonitor.cpp	2010-01-11 13:21:43 UTC (rev 95)
+++ trunk/SmartCardServices/src/PCSC/pcscdmonitor.cpp	2010-01-11 13:31:59 UTC (rev 96)
@@ -1101,8 +1101,8 @@
 	{
 		std::string vendorName, productName, serialNumber, name;
 
-		uint32_t vendorID, productID;
-		bool isPCCard;
+		uint32_t vendorID = 0, productID = 0;
+		bool isPCCard = false;
 		
 		CFRef<CFStringRef> ioName = static_cast<CFStringRef>(::IORegistryEntryCreateCFProperty(
 			service, CFSTR(kzIOPCCardIONameKey), kCFAllocatorDefault, 0));