https://bugs.kde.org/show_bug.cgi?id=485756

            Bug ID: 485756
           Summary: ktorrent bad_alloc
    Classification: Applications
           Product: ktorrent
           Version: 23.08.5
          Platform: Other
                OS: Other
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: general
          Assignee: joris.guis...@gmail.com
          Reporter: lg3dx...@gmail.com
  Target Milestone: ---

***
If you're not sure this is actually a bug, instead post about it at
https://discuss.kde.org

If you're reporting a crash, attach a backtrace with debug symbols; see
https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***

SUMMARY


STEPS TO REPRODUCE
1. Maybe try download a torrent at 100 MiB/sec ?
2. Have bunch of free memory ( 18 GB full-free, though 50GB available if use
what is for caches, and +750GB of swap space)
3. 

OBSERVED RESULT
crash

EXPECTED RESULT


SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: gentoo linux kde plasma stable gcc -O3 -flto 
(available in About System)
KDE Plasma Version: 5.27.11
KDE Frameworks Version:  5.115
Qt Version: 5.15.12

ADDITIONAL INFORMATION

backtrace from gdb:

```
gdb ktorrent
GNU gdb (Gentoo 14.1 vanilla) 14.1
Copyright (C) 2023 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-pc-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://bugs.gentoo.org/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ktorrent...
(gdb) r
Starting program: /usr/bin/ktorrent 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
[New Thread 0x7fffeb7ff6c0 (LWP 84380)]
[New Thread 0x7fffeaffe6c0 (LWP 84381)]
[New Thread 0x7fffea7fd6c0 (LWP 84382)]
[New Thread 0x7fffe9bff6c0 (LWP 84383)]
[New Thread 0x7fffe93fe6c0 (LWP 84384)]
[New Thread 0x7fffe8bfd6c0 (LWP 84385)]
[Thread 0x7fffe8bfd6c0 (LWP 84385) exited]
[Thread 0x7fffe9bff6c0 (LWP 84383) exited]
[Thread 0x7fffe93fe6c0 (LWP 84384) exited]
[New Thread 0x7fffe93fe6c0 (LWP 84387)]
[New Thread 0x7fffe9bff6c0 (LWP 84388)]
[New Thread 0x7fffe8bfd6c0 (LWP 84389)]
[Thread 0x7fffe8bfd6c0 (LWP 84389) exited]
[Thread 0x7fffe9bff6c0 (LWP 84388) exited]
[Thread 0x7fffe93fe6c0 (LWP 84387) exited]
[New Thread 0x7fffe9bff6c0 (LWP 84390)]
[New Thread 0x7fffe93fe6c0 (LWP 84391)]
[Thread 0x7fffe9bff6c0 (LWP 84390) exited]
[New Thread 0x7fffe9bff6c0 (LWP 84401)]
[Thread 0x7fffe9bff6c0 (LWP 84401) exited]
[New Thread 0x7fffe9bff6c0 (LWP 84402)]
[Thread 0x7fffe9bff6c0 (LWP 84402) exited]
[New Thread 0x7fffe9bff6c0 (LWP 84406)]
[New Thread 0x7fffe8bfd6c0 (LWP 84407)]
Error Opening file /usr/share/GeoIP/GeoIP.dat
[New Thread 0x7fffd363c6c0 (LWP 84425)]
[New Thread 0x7fffd2e3b6c0 (LWP 84426)]
[New Thread 0x7fffd263a6c0 (LWP 84427)]
[New Thread 0x7fffd1e396c0 (LWP 84428)]
[Detaching after fork from child process 84429]
[Detaching after fork from child process 84437]
[Detaching after fork from child process 84440]
[Detaching after fork from child process 84442]
[New Thread 0x7fffb021f6c0 (LWP 84444)]
[New Thread 0x7fffafa1e6c0 (LWP 84445)]
[New Thread 0x7fffaf21d6c0 (LWP 84446)]
[New Thread 0x7fffaea1c6c0 (LWP 84447)]
[Thread 0x7fffb021f6c0 (LWP 84444) exited]
[Thread 0x7fffafa1e6c0 (LWP 84445) exited]
[Thread 0x7fffaf21d6c0 (LWP 84446) exited]
[Thread 0x7fffaea1c6c0 (LWP 84447) exited]
[New Thread 0x7fffaea1c6c0 (LWP 84463)]
[Thread 0x7fffaea1c6c0 (LWP 84463) exited]
[New Thread 0x7fffaea1c6c0 (LWP 84464)]
[New Thread 0x7fffaf21d6c0 (LWP 84465)]
[New Thread 0x7fffafa1e6c0 (LWP 84466)]
[Thread 0x7fffd263a6c0 (LWP 84427) exited]
[Thread 0x7fffd2e3b6c0 (LWP 84426) exited]
[Thread 0x7fffd363c6c0 (LWP 84425) exited]
[Thread 0x7fffd1e396c0 (LWP 84428) exited]
Warning: Qt has caught an exception thrown from an event handler. Throwing
exceptions from an event handler is not supported in Qt.
You must not let any exception whatsoever propagate through Qt code.
If that is not possible, in Qt 5 you must at least reimplement
QCoreApplication::notify() and catch all exceptions there.

terminate called after throwing an instance of 'std::bad_alloc'
  what():  std::bad_alloc

Thread 1 "ktorrent" received signal SIGABRT, Aborted.
__pthread_kill_implementation (threadid=<optimized out>, signo=signo@entry=6,
no_tid=no_tid@entry=0) at pthread_kill.c:44
44           return INTERNAL_SYSCALL_ERROR_P (ret) ? INTERNAL_SYSCALL_ERRNO
(ret) : 0;
(gdb) bt
#0  __pthread_kill_implementation (threadid=<optimized out>,
signo=signo@entry=6, no_tid=no_tid@entry=0) at pthread_kill.c:44
#1  0x00007ffff54af5df in __pthread_kill_internal (signo=6, threadid=<optimized
out>) at pthread_kill.c:78
#2  0x00007ffff5460612 in __GI_raise (sig=sig@entry=6) at
../sysdeps/posix/raise.c:26
#3  0x00007ffff54494ed in __GI_abort () at abort.c:79
#4  0x00007ffff56a0b32 in __gnu_cxx::__verbose_terminate_handler ()
    at
/usr/src/debug/sys-devel/gcc-13.2.1_p20240113-r1/gcc-13-20240113/libstdc++-v3/libsupc++/vterminate.cc:95
#5  0x00007ffff56b44e6 in __cxxabiv1::__terminate (handler=<optimized out>)
    at
/usr/src/debug/sys-devel/gcc-13.2.1_p20240113-r1/gcc-13-20240113/libstdc++-v3/libsupc++/eh_terminate.cc:48
#6  0x00007ffff56b3179 in __cxa_call_terminate (ue_header=0x55555762a860)
    at
/usr/src/debug/sys-devel/gcc-13.2.1_p20240113-r1/gcc-13-20240113/libstdc++-v3/libsupc++/eh_call.cc:54
#7  0x00007ffff56b385c in __cxxabiv1::__gxx_personality_v0
    (version=<optimized out>, actions=6, exception_class=5138137972254386944,
ue_header=<optimized out>, context=<optimized out>)
    at
/usr/src/debug/sys-devel/gcc-13.2.1_p20240113-r1/gcc-13-20240113/libstdc++-v3/libsupc++/eh_personality.cc:688
#8  0x00007ffff6fbc6a4 in _Unwind_RaiseException_Phase2
    (exc=exc@entry=0x55555762a860, context=context@entry=0x7fffffffceb0,
frames_p=frames_p@entry=0x7fffffffcdb8)
    at
/usr/src/debug/sys-devel/gcc-13.2.1_p20240113-r1/gcc-13-20240113/libgcc/unwind.inc:64
#9  0x00007ffff6fbcf84 in _Unwind_Resume (exc=exc@entry=0x55555762a860)
    at
/usr/src/debug/sys-devel/gcc-13.2.1_p20240113-r1/gcc-13-20240113/libgcc/unwind.inc:242
#10 0x00007ffff7d8da35 in bt::TorrentControl::stop (this=<optimized out>,
wjob=0x0)
    at
/usr/src/debug/net-libs/libktorrent-23.08.5/libktorrent-23.08.5/src/torrent/torrentcontrol.cpp:452
#11 0x00007ffff7dff584 in bt::TorrentControl::~TorrentControl
(this=0x555555f4b610, this=<optimized out>)
    at
/usr/src/debug/net-libs/libktorrent-23.08.5/libktorrent-23.08.5/src/torrent/torrentcontrol.cpp:104
#12 0x00007ffff7dff639 in bt::TorrentControl::~TorrentControl
(this=0x555555f4b610, this=<optimized out>)
    at
/usr/src/debug/net-libs/libktorrent-23.08.5/libktorrent-23.08.5/src/torrent/torrentcontrol.cpp:124
#13 0x00007ffff7f3833e in
qDeleteAll<QList<bt::TorrentInterface*>::const_iterator> (end=..., begin=...)
at /usr/include/qt5/QtCore/qalgorithms.h:320
#14 qDeleteAll<kt::QueuePtrList> (c=...) at
/usr/include/qt5/QtCore/qalgorithms.h:328
#15 kt::QueueManager::~QueueManager (this=0x555555f034f0, this=<optimized out>)
    at
/usr/src/debug/net-p2p/ktorrent-23.08.5/ktorrent-23.08.5/libktcore/torrent/queuemanager.cpp:53
#16 0x00007ffff7f383b9 in kt::QueueManager::~QueueManager (this=0x555555f034f0,
this=<optimized out>)
    at
/usr/src/debug/net-p2p/ktorrent-23.08.5/ktorrent-23.08.5/libktcore/torrent/queuemanager.cpp:54
#17 0x00005555555bc51a in kt::Core::~Core (this=0x555555ef8fc0, this=<optimized
out>)
    at
/usr/src/debug/net-p2p/ktorrent-23.08.5/ktorrent-23.08.5/ktorrent/core.cpp:115
#18 0x00005555555ca82e in kt::Core::~Core (this=0x555555ef8fc0, this=<optimized
out>)
    at
/usr/src/debug/net-p2p/ktorrent-23.08.5/ktorrent-23.08.5/ktorrent/core.cpp:113
#19 kt::GUI::~GUI (this=0x7fffffffd290, this=<optimized out>) at
/usr/src/debug/net-p2p/ktorrent-23.08.5/ktorrent-23.08.5/ktorrent/gui.cpp:116
#20 0x00005555555b0093 in main (argc=<optimized out>, argv=<optimized out>) at
/usr/src/debug/net-p2p/ktorrent-23.08.5/ktorrent-23.08.5/ktorrent/main.cpp:251

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to