Bug 262589

Summary: [XIOError] Ktorrent 4.0.5 crashes during/shortly after initializations when downloading/seeding many torrents.
Product: [Applications] ktorrent Reporter: thordn
Component: generalAssignee: Joris Guisson <joris.guisson>
Status: RESOLVED NOT A BUG    
Severity: crash CC: adrian, andysem
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Slackware   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: Info from KDE crashhandler.
Logfile from valgrind run.

Description thordn 2011-01-08 21:38:07 UTC
Created attachment 55747 [details]
Info from KDE crashhandler.

Version:           unspecified (using KDE 4.4.3) 
OS:                Linux

Using ktorrent 4.0.5 with patches from bug 261903 compiled from sources.

Reproducible: Always

Steps to Reproduce:
I had set max-open-files-for-user to 19,999 in the OS, had ktorrent with about 4400 torrents loaded of which about 1000 was possible to seed.

I then increased max torrents to download and to seed to 2000 each. Ktorren then showed in upper left: "All torrents 3005/4400" (about 4400).

Exit ktorrent, then started it again. 


Actual Results:  
After a few minutes it crashed with a segfault, GUI was not responsive so no chance to change any parameters there. Tried this about 5 times. Did a run under valgrind, no crash after 5 hours, got a segfault when terminating it, see log vg2.log. 

Expected Results:  
Normal operation or limiting the number of up/downloads if problem detected.
Comment 1 thordn 2011-01-08 21:39:02 UTC
Created attachment 55748 [details]
Logfile from valgrind run.
Comment 2 Joris Guisson 2011-01-12 19:16:14 UTC
Crash triggered by an XIOError, not sure what could be causing this.
Comment 3 Joris Guisson 2011-04-08 11:19:33 UTC
*** Bug 270239 has been marked as a duplicate of this bug. ***
Comment 4 Adrián Chaves (Gallaecio) 2012-10-01 04:38:23 UTC
Can you reproduce this error with a newer version of KTorrent?
Comment 5 Lastique 2012-10-01 06:39:43 UTC
(In reply to comment #4)
> Can you reproduce this error with a newer version of KTorrent?

I now run KDE 4.8.5 and I don't have these crashes. Sorry, can't remember KTorrent version.
Comment 6 Joris Guisson 2012-10-01 18:19:39 UTC
OK, do not set max-open-files-for-user to anything but the default. KTorrent can handle this without problems, but for example Qt can't, and as result things can crash. libX11 seems to have the same problem, looking at it's source code, which probably triggers the XIOError