Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-09-10 Thread sebastiank
On 06.09.2012 00:45, Pete Batard wrote: > We haven't seen crash reports from you since we pushed the fixes that > (we hoped) could address the issue. Can you confirm that you've been > happily running pcscd ever since? Hello Pete, sorry for my delayed response. I have been out of office for a

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-24 Thread sebastiank
On 2012-08-23 21:51, Pete Batard wrote: > Could be a problem with output redirection in pcscd then, rather than a > libusbx issue. The only component that has been altered is libusbx. I did the lib compiling the same way I did the last several weeks. So indeed, it was surprising. Just wanted to inf

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-23 Thread sebastiank
On 2012-08-22 23:16, Pete Batard wrote: > I have now pushed Peter's patch... THANK YOU VERY MUCH TO ALL OF YOU!!! I have distributed the new version to the prod machines today. While testing the new version (git mainline 1.0.12.10553) on the test machine, I recognised the following strange behavi

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-22 Thread sebastiank
Hello Peter, On 22.08.2012 10:39, Peter Stuge wrote: > Here's a patch to fix that bug, but I'm not sure if it is enough to > completely solve the problem. thank you for the patch. I hope that it will solve it. = Regards Sebastian =

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-22 Thread sebastiank
On 16.08.2012 22:46, Pete Batard wrote: > If you're using the version of libusbx with the latest patches, we > will get the needed inisght about the cause for the error. I'm using the latest git-mainline version of libusbx on all machines, with the extra debugging output you advised me to include.

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-16 Thread sebastiank
On 2012.08.15 23:18, Pete Batard wrote: > By the looks of it, the error you got on the test environment isn't the > same as the one you get in prod, though I still wouldn't mind figuring > out the cause of what happened in test. The test machine is still running with LIBUSB_DEBUG set to 4. Do you k

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-15 Thread sebastiank
> On 2012.08.13 11:00, sebastiank wrote: > > On 2012.08.12 23:59, Pete Batard wrote: > > Patch has now been pushed to the mailine git libusbx repository (along > > with other minor changes. See > > https://github.com/libusbx/libusbx/commits/master for details. >

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-13 Thread sebastiank
> On 2012.08.12 23:59, Pete Batard wrote: > Patch has now been pushed to the mailine git libusbx repository (along > with other minor changes. See > https://github.com/libusbx/libusbx/commits/master for details. Thank you very much! The new version is now active on the production machines, along w

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-10 Thread sebastiank
> On 2012.08.09 22:25, Pete Batard wrote: > OK, first thing I notice is that the timerfd report is output as a > warning rather than debug, so if your test machine is behaving the same > way as your other server, it means that you have silenced warnings > there, which I'd strongly recommend against

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-07 Thread sebastiank
Just for information: I got another core dump with the libusbx compiled on monday. Are you interested in this one? Program terminated with signal 11, Segmentation fault. #0 0x00115e89 in add_to_flying_list (transfer=0xb5600468) at io.c:1175 1175io.c: Datei oder Verzeichnis nicht gefunden.

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-07 Thread sebastiank
> On 2012.08.07 12:44, Pete Batard wrote: > Did you get the impression that crash happened sooner than the previous > ones this time around, or what is about the same? Very hard to say. To me it seems that the failure occurs totally randomly. Sometimes after some hours, sometimes after several day

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-07 Thread sebastiank
Good morning Pete, Ludovic and Orin, yesterday, I recompiled the latest libusbx version from the git repository with debug information (version 1.0.12.10545) and replaced it on the computers. > On 2012.08.03 15:51, Pete Batard wrote: > If you do observe the crash again, and since you're recompil

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-03 Thread sebastiank
Hi, > On 2012.08.03 15:51, Pete Batard wrote: > Sebastian, > > can you try recompiling and installing libusbx from the latest git version? I'll try to recompile and replace libusbx on Monday. > On 2012.08.03 15:51, Pete Batard wrote: > If you do observe the crash again, and since you're recompil

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-02 Thread sebastiank
> On 2012.08.02 14:08, sebastiank wrote: > (gdb) print (struct usbi_transfer)0xb6600468 > Invalid cast. For the first backtrace: #0 0x00697e9b in add_to_flying_list (transfer=0xb6600468) at io.c:1185 (gdb) print ((struct usbi_transfer*)0xb6600468)->num_iso_packets $1 = 0 (gdb) pr

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-02 Thread sebastiank
> On 2012.08.02 13:58, Pete Batard wrote: > I think 'print (struct usbi_transfer)0xb6600468' should do but if that > doesn't work, the hex dump should do just fine. (gdb) print (struct usbi_transfer)0xb6600468 Invalid cast. For the first backtrace: (gdb) x 0xb6600468 0xb6600468: 0x (

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-02 Thread sebastiank
Hello Pete, please see the lines below. For the first backtrace: (gdb) print &ctx->flying_transfers $3 = (struct list_head *) 0x9088ed8 For the second backtrace: (gdb) print &ctx->flying_transfers $3 = (struct list_head *) 0x8b63ed8 = Regards Sebastian =

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-02 Thread sebastiank
For the first backtrace: (gdb) print *cur Cannot access memory at address 0xfffc (gdb) print *ctx $1 = {debug = 0, debug_fixed = 0, ctrl_pipe = {8, 9}, usb_devs = {prev = 0x9089010, next = 0x90899c0}, usb_devs_lock = {__data = {__lock = 0, __count = 0, __owner = 0, __kind = 0, __nusers = 0,

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-02 Thread sebastiank
Hello Ludovic, > On 2012.08.02 10:19, Ludovic Rousseau wrote: > In gdb can you display the different variables using: This is the output for the first backtrace I send today: #0 0x00697e9b in add_to_flying_list (transfer=0xb6600468) at io.c:1185 1185io.c: Datei oder Verzeichnis nicht gefunde

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-02 Thread sebastiank
Just got another segmentation fault. The Backtrace differs from the previous one. = Regards Sebastian = gdb /usr/sbin/pcscd core GNU gdb (GDB) 7.1-ubuntu Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-08-01 Thread sebastiank
> On 2012.07.28 12:06, Ludovic Rousseau wrote: > You would get more detailed information by rebuilding libusbx with debug > info. As you suggested, I compiled libusbx with debug info. I'd like you to have a final look at the attached backtrace and confirm that the segmentation fault is related to

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-29 Thread sebastiank
> On 2012.07.28 15:51, Ludovic Rousseau wrote: > I am a libusbx maintainer :-) Sorry, I did not want to underestimate your position in the libusbx project. > On 2012.07.28 15:51, Ludovic Rousseau wrote: > Different backtrace but they both indicate a crash in libusbx with no > (direct) relation wit

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-28 Thread sebastiank
Did you have a look at the second file as well? It seems to me that there are two different issues (different function calls). > On 2012.07.28 12:06, Ludovic Rousseau wrote: > It looks like the thread is started by the okccid driver itlself and > not by pcscd. If the libusbx maintainers agree wit

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-28 Thread sebastiank
> On 2012.07.28 11:46:37, Ludovic Rousseau wrote: > Now you can use the core files to get the backtrace. > > Do: > $ gdb -c core > [...] > (gdb) backtrace I already did the backtrace for each core dump. Please have a look at the txt-files. = Regards Sebastian = ---

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-23 Thread sebastiank
> On 2012.07.23 13:51, sebastiank wrote: >> On 2012.07.21 20:29, Ludovic Rousseau wrote: >> You may have to play with "ulimit -c unlimited" to allow the creation >> of a core file. > After doing some research about ulimit, I’m afraid to say that I can’t >

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-23 Thread sebastiank
> On 2012.07.21 20:29, Ludovic Rousseau wrote: > Can you try to make pcscd generate a core file? Does this imply that the usbmon output is not useful and can be disabled? > You may have to play with "ulimit -c unlimited" to allow the creation > of a core file. After doing some research about uli

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-20 Thread sebastiank
> On 2012.07.19 21:08, Pete Batard wrote: > I will actually take this opportunity to apologize to the list for > approving the message, before realizing it was being held due to the > size of its attachment, as it may inconvenience some. I have to apologize to the list members for not compressing

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-10 Thread sebastiank
Hello Pete, today, I was able to redirect the libusbx debug information (log level 4) to a file in the test environment: 'LIBUSB_DEBUG=4 /usr/sbin/pcscd --foreground --debug --apdu &> /var/log/pcscd.log' Setting the log level to 4 generates huge CPU load and the log file grows very fast (200-

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-09 Thread sebastiank
Hi, I’ll give you a short summary, on what I did so far: - I installed the latest version of libusb-1.0-0 (libusbx 1.0.12 - debian package) - I set up rsyslog and logrotate like Pete suggested - I modified the /etc/init.d/pcscd script -> ‘export LIBUSB_DEBUG=3’ - I created the file /etc/default/p

Re: [Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-03 Thread sebastiank
First of all, I’d like to thank you both very much for your fast response. I use pcsc in a productive environment (24/7), where contactless smardcards are used to grant access to an application. Because there are more than 25 pc-terminals involved, I’d appreciate a non disturbing and simple way

[Libusbx-devel] libusb segfaults - causes pcscd to crash

2012-07-03 Thread sebastiank
Dear maintainer, I encountered an issue using pcsc-lite and libusb on Ubuntu 10.04 LTS. Now and then libusb segfaults and causes pcscd to crash. The error occurred with libusb-1.0-0 (1.0.8), so I updated libusb-1.0-0 and libusb-1.0-0-dev to 1.0.11 (libusbx) a few days ago, hoping the issue was f