[Pcsclite-cvs-commit] r2834 - /trunk/PCSC/src/winscard_clnt.c
rousseau at users.alioth.debian.org
rousseau at users.alioth.debian.org
Tue Feb 19 13:38:40 UTC 2008
Author: rousseau
Date: Tue Feb 19 13:38:39 2008
New Revision: 2834
URL: http://svn.debian.org/wsvn/pcsclite/?sc=1&rev=2834
Log:
SCardReleaseContext(): do not call SCardGetContextIndice() since
SCardRemoveContext() will call it internally
Modified:
trunk/PCSC/src/winscard_clnt.c
Modified: trunk/PCSC/src/winscard_clnt.c
URL: http://svn.debian.org/wsvn/pcsclite/trunk/PCSC/src/winscard_clnt.c?rev=2834&op=diff
==============================================================================
--- trunk/PCSC/src/winscard_clnt.c (original)
+++ trunk/PCSC/src/winscard_clnt.c Tue Feb 19 13:38:39 2008
@@ -569,18 +569,13 @@
PROFILE_START
/*
- * Make sure this context has been opened
- */
- dwContextIndex = SCardGetContextIndice(hContext);
- if (dwContextIndex == -1)
- return SCARD_E_INVALID_HANDLE;
-
- /*
* Remove the local context from the stack
*/
SCardLockThread();
- SCardRemoveContext(hContext);
+ rv = SCardRemoveContext(hContext);
SCardUnlockThread();
+ if (rv != SCARD_S_SUCCESS)
+ return rv;
if (SCardCheckDaemonAvailability() != SCARD_S_SUCCESS)
return SCARD_E_NO_SERVICE;
More information about the Pcsclite-cvs-commit
mailing list