[Pcsclite-muscle] Problem (sigsegv) on reconnect.
Ludovic Rousseau
ludovic.rousseau
Tue Jun 23 09:06:00 PDT 2015
Hello Luc,
2015-06-23 13:28 GMT+02:00 Ludovic Rousseau <ludovic.rousseau at gmail.com>:
> 2015-06-19 11:57 GMT+02:00 <luc.mazardo at orange.com>:
>> Hello,
>>
>> On 12/06/2015 16:33, Ludovic Rousseau wrote:
>>
>>> Are you using threads in your application?
>> Yes
>>
>>> Does each thread use its own PC/SC context (SCardEstablishContext)?
>> No, we use javax.smartcardio based on SCardEstablishContext called by
>> PCSCTerminals.initContext().
>> initContext() is called at the time the shared object (libpcsc.so*) is
>> opened.
>> The implementation of initContext() keeps the result in a singleton.
>>
>> <code from="openjdk-7-fcs-src-b147-27_jun_2011">
>> static synchronized void initContext() throws PCSCException {
>> if (contextId == 0) {
>> contextId = SCardEstablishContext(SCARD_SCOPE_USER);
>> }
>>
>> </code>
>
> OK. I am working on the issue.
>
> Locking and threading problems are not easy. I do not want to
> introduce regressions.
Luc, can you test the pcsc-lite beta version available at
http://ludovic.rousseau.free.fr/softwares/pcsc-lite/
It should fix your issue. I have not tried your Java code. So maybe I
missed something.
Bye
--
Dr. Ludovic Rousseau
More information about the pcsclite-muscle
mailing list