[Pcsclite-muscle] Asynchronous PCSC API
Ludovic Rousseau
ludovic.rousseau at gmail.com
Sun Jan 30 04:49:39 PST 2022
Le sam. 29 janv. 2022 à 21:29, Stephan Brunner
<s.brunner at stephan-brunner.net> a écrit :
>
> Hi,
Hello Stephan,
> I'm not very sure about that one as I haven't done anything recent with
> PCSC on Windows, but I think SCardCancel has to be issued on the same
> handle as the request, thus doing it in the same process on different
> threads. And not on a different process or with a different handle.
This is exactly what cardlock_cancel.c is doing.
https://github.com/eugmes/cardlock/blob/master/cardlock_cancel.c#L92
Ievgenii published the complete project at https://github.com/eugmes/cardlock
The samples should work on GNU/Linux, Windows and macOS.
> Otherwise I'd imagine the second context won't get a lock on the reader
> or something like that.
The other process cardlock.c is (just) used to start a PC/SC
transaction and lock the access to the card.
https://github.com/eugmes/cardlock/blob/master/cardlock.c
If someone can run the sample codes on Windows and get a working
SCardCancel() that would help.
Bye
--
Dr. Ludovic Rousseau
More information about the pcsclite-muscle
mailing list