[Pcsclite-git-commit] [pcsc-tools] 27/32: pcsc_scan: ignore same state
Ludovic Rousseau
rousseau at moszumanska.debian.org
Thu May 4 15:44:49 UTC 2017
This is an automated email from the git hooks/post-receive script.
rousseau pushed a commit to branch master
in repository pcsc-tools.
commit e1a76f2a903d101198c70b7f65dd3f3a1157663d
Author: Ludovic Rousseau <ludovic.rousseau at free.fr>
Date: Sat Apr 8 18:18:04 2017 +0200
pcsc_scan: ignore same state
On macOS SCardGetStatusChange() set SCARD_STATE_CHANGED even
if the state has _not_ changed.
The bit is not reset.
---
pcsc_scan.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/pcsc_scan.c b/pcsc_scan.c
index 70d1c9f..623a772 100644
--- a/pcsc_scan.c
+++ b/pcsc_scan.c
@@ -454,6 +454,12 @@ get_readers:
* happened */
for (current_reader=0; current_reader < nbReaders; current_reader++)
{
+#ifdef __APPLE__
+ if (rgReaderStates_t[current_reader].dwCurrentState ==
+ rgReaderStates_t[current_reader].dwEventState)
+ continue;
+#endif
+
if (rgReaderStates_t[current_reader].dwEventState &
SCARD_STATE_CHANGED)
{
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pcsclite/pcsc-tools.git
More information about the Pcsclite-cvs-commit
mailing list