[Pcsclite-git-commit] [PCSC] 08/16: SCardRemoveHandle() returns void now

Ludovic Rousseau rousseau at moszumanska.debian.org
Thu May 11 16:26:04 UTC 2017


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

rousseau pushed a commit to branch master
in repository PCSC.

commit d3b1b7217325f67db27a6d5519294c5b65003266
Author: Ludovic Rousseau <ludovic.rousseau at free.fr>
Date:   Thu May 11 14:50:05 2017 +0200

    SCardRemoveHandle() returns void now
    
    The value returned by SCardRemoveHandle() was ignored.
    Now the SCardRemoveHandle() function returns void.
---
 src/winscard_clnt.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/winscard_clnt.c b/src/winscard_clnt.c
index d6b40fc..538e85c 100644
--- a/src/winscard_clnt.c
+++ b/src/winscard_clnt.c
@@ -382,7 +382,7 @@ static LONG SCardGetContextChannelAndLockFromHandle(SCARDHANDLE,
 	/*@out@*/ SCONTEXTMAP * *, /*@out@*/ CHANNEL_MAP * *);
 static LONG SCardGetContextAndChannelFromHandleTH(SCARDHANDLE,
 	/*@out@*/ SCONTEXTMAP * *, /*@out@*/ CHANNEL_MAP * *);
-static LONG SCardRemoveHandle(SCARDHANDLE);
+static void SCardRemoveHandle(SCARDHANDLE);
 
 static LONG SCardGetSetAttrib(SCARDHANDLE hCard, int command, DWORD dwAttrId,
 	LPBYTE pbAttr, LPDWORD pcbAttrLen);
@@ -1081,7 +1081,7 @@ LONG SCardDisconnect(SCARDHANDLE hCard, DWORD dwDisposition)
 		goto end;
 
 	if (SCARD_S_SUCCESS == scDisconnectStruct.rv)
-		(void)SCardRemoveHandle(hCard);
+		SCardRemoveHandle(hCard);
 	rv = scDisconnectStruct.rv;
 
 end:
@@ -3414,7 +3414,7 @@ static LONG SCardAddHandle(SCARDHANDLE hCard, SCONTEXTMAP * currentContextMap,
 	return SCARD_S_SUCCESS;
 }
 
-static LONG SCardRemoveHandle(SCARDHANDLE hCard)
+static void SCardRemoveHandle(SCARDHANDLE hCard)
 {
 	SCONTEXTMAP * currentContextMap;
 	CHANNEL_MAP * currentChannelMap;
@@ -3424,7 +3424,7 @@ static LONG SCardRemoveHandle(SCARDHANDLE hCard)
 	rv = SCardGetContextAndChannelFromHandleTH(hCard, &currentContextMap,
 		&currentChannelMap);
 	if (rv == -1)
-		return SCARD_E_INVALID_HANDLE;
+		return;
 
 	free(currentChannelMap->readerName);
 
@@ -3437,7 +3437,7 @@ static LONG SCardRemoveHandle(SCARDHANDLE hCard)
 
 	free(currentChannelMap);
 
-	return SCARD_S_SUCCESS;
+	return;
 }
 
 static LONG SCardGetContextChannelAndLockFromHandle(SCARDHANDLE hCard,

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



More information about the Pcsclite-cvs-commit mailing list