Bug 383000 - K3B crashes from time to tiem
Summary: K3B crashes from time to tiem
Status: RESOLVED WORKSFORME
Alias: None
Product: k3b
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR crash
Target Milestone: ---
Assignee: k3b developers
URL:
Keywords: drkonqi
Depends on:
Blocks:
 
Reported: 2017-08-01 13:59 UTC by Michael Lashkevich
Modified: 2021-01-16 04:36 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Lashkevich 2017-08-01 13:59:29 UTC
Application: k3b (17.04.2)

Qt Version: 5.6.1
Frameworks Version: 5.32.0
Operating System: Linux 4.4.74-18.20-default x86_64
Distribution: "openSUSE Leap 42.2"

-- Information about the crash:
- What I was doing when the application crashed:
K3B crashes from time to time, when I close the burning menu after burning or try to start another action.

-- Backtrace:
Application: K3b (k3b), signal: Segmentation fault
Using host libthread_db library "/lib64/libthread_db.so.1".
[Current thread is 1 (Thread 0x7ff55c7a9900 (LWP 29723))]

Thread 4 (Thread 0x7ff51cb2f700 (LWP 30417)):
#0  0x00007ff5566bb28d in read () at /lib64/libc.so.6
#1  0x00007ff549c15871 in pa_read () at /usr/lib64/pulseaudio/libpulsecommon-10.0.so
#2  0x00007ff54d3181ce in pa_mainloop_prepare () at /usr/lib64/libpulse.so.0
#3  0x00007ff54d318be2 in pa_mainloop_iterate () at /usr/lib64/libpulse.so.0
#4  0x00007ff54d318ca0 in pa_mainloop_run () at /usr/lib64/libpulse.so.0
#5  0x00007ff54d326de6 in  () at /usr/lib64/libpulse.so.0
#6  0x00007ff549c44388 in  () at /usr/lib64/pulseaudio/libpulsecommon-10.0.so
#7  0x00007ff550e71744 in start_thread () at /lib64/libpthread.so.0
#8  0x00007ff5566c7aad in clone () at /lib64/libc.so.6

Thread 3 (Thread 0x7ff527b49700 (LWP 30412)):
#0  0x00007ff55669805d in nanosleep () at /lib64/libc.so.6
#1  0x00007ff556e6486d in  () at /usr/lib64/libQt5Core.so.5
#2  0x00007ff556db8deb in QThread::sleep(unsigned long) () at /usr/lib64/libQt5Core.so.5
#3  0x00007ff55c2b4055 in K3b::MediaCache::PollThread::run() () at /usr/lib64/libk3blib.so.7
#4  0x00007ff556db99e9 in  () at /usr/lib64/libQt5Core.so.5
#5  0x00007ff550e71744 in start_thread () at /lib64/libpthread.so.0
#6  0x00007ff5566c7aad in clone () at /lib64/libc.so.6

Thread 2 (Thread 0x7ff541f99700 (LWP 29726)):
#0  0x00007ff550929730 in g_ptr_array_set_size () at /usr/lib64/libglib-2.0.so.0
#1  0x00007ff5509538b1 in g_main_context_prepare () at /usr/lib64/libglib-2.0.so.0
#2  0x00007ff550954230 in  () at /usr/lib64/libglib-2.0.so.0
#3  0x00007ff55095442c in g_main_context_iteration () at /usr/lib64/libglib-2.0.so.0
#4  0x00007ff556fcc33b in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Core.so.5
#5  0x00007ff556f79feb in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Core.so.5
#6  0x00007ff556db4f1a in QThread::exec() () at /usr/lib64/libQt5Core.so.5
#7  0x00007ff5573e0295 in  () at /usr/lib64/libQt5DBus.so.5
#8  0x00007ff556db99e9 in  () at /usr/lib64/libQt5Core.so.5
#9  0x00007ff550e71744 in start_thread () at /lib64/libpthread.so.0
#10 0x00007ff5566c7aad in clone () at /lib64/libc.so.6

Thread 1 (Thread 0x7ff55c7a9900 (LWP 29723)):
[KCrash Handler]
#6  0x0000000000000020 in  ()
#7  0x00007ff5563c5d84 in KFileMetaData::Extractor::~Extractor() () at /usr/lib64/libKF5FileMetaData.so.3
#8  0x00007ff5563c5da9 in KFileMetaData::Extractor::~Extractor() () at /usr/lib64/libKF5FileMetaData.so.3
#9  0x00007ff5563c741f in KFileMetaData::ExtractorCollection::~ExtractorCollection() () at /usr/lib64/libKF5FileMetaData.so.3
#10 0x00007ff55c2c636e in K3b::AudioDecoder::~AudioDecoder() () at /usr/lib64/libk3blib.so.7
#11 0x00007ff528d95299 in  () at /usr/lib64/qt5/plugins/k3bmaddecoder.so
#12 0x00007ff55c323fc4 in K3b::AudioDoc::decreaseDecoderUsage(K3b::AudioDecoder*) () at /usr/lib64/libk3blib.so.7
#13 0x00007ff55c328592 in K3b::AudioFile::~AudioFile() () at /usr/lib64/libk3blib.so.7
#14 0x00007ff55c3285b9 in K3b::AudioFile::~AudioFile() () at /usr/lib64/libk3blib.so.7
#15 0x00007ff55c319f25 in K3b::AudioTrack::~AudioTrack() () at /usr/lib64/libk3blib.so.7
#16 0x00007ff55c31a059 in K3b::AudioTrack::~AudioTrack() () at /usr/lib64/libk3blib.so.7
#17 0x00007ff55c3201fe in K3b::AudioDoc::~AudioDoc() () at /usr/lib64/libk3blib.so.7
#18 0x00007ff55c320489 in K3b::AudioDoc::~AudioDoc() () at /usr/lib64/libk3blib.so.7
#19 0x00000000004867e4 in  ()
#20 0x00007ff55a7bde74 in KMainWindow::closeEvent(QCloseEvent*) () at /usr/lib64/libKF5XmlGui.so.5
#21 0x00007ff557f46c68 in QWidget::event(QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#22 0x00007ff5580570cb in QMainWindow::event(QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#23 0x00007ff55a7be057 in KMainWindow::event(QEvent*) () at /usr/lib64/libKF5XmlGui.so.5
#24 0x00007ff55a7fac45 in KXmlGuiWindow::event(QEvent*) () at /usr/lib64/libKF5XmlGui.so.5
#25 0x00007ff557f04e3c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#26 0x00007ff557f0949a in QApplication::notify(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#27 0x00007ff556f7bfd5 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib64/libQt5Core.so.5
#28 0x00007ff557f41fa9 in QWidgetPrivate::close_helper(QWidgetPrivate::CloseMode) () at /usr/lib64/libQt5Widgets.so.5
#29 0x00007ff557f5eea6 in  () at /usr/lib64/libQt5Widgets.so.5
#30 0x00007ff557f61e53 in  () at /usr/lib64/libQt5Widgets.so.5
#31 0x00007ff557f04e3c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#32 0x00007ff557f0949a in QApplication::notify(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#33 0x00007ff556f7bfd5 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib64/libQt5Core.so.5
#34 0x00007ff55774ee3c in QGuiApplicationPrivate::processCloseEvent(QWindowSystemInterfacePrivate::CloseEvent*) () at /usr/lib64/libQt5Gui.so.5
#35 0x00007ff557752e35 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) () at /usr/lib64/libQt5Gui.so.5
#36 0x00007ff557734eeb in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Gui.so.5
#37 0x00007ff545e72bc0 in  () at /usr/lib64/libQt5XcbQpa.so.5
#38 0x00007ff550954134 in g_main_context_dispatch () at /usr/lib64/libglib-2.0.so.0
#39 0x00007ff550954388 in  () at /usr/lib64/libglib-2.0.so.0
#40 0x00007ff55095442c in g_main_context_iteration () at /usr/lib64/libglib-2.0.so.0
#41 0x00007ff556fcc31c in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Core.so.5
#42 0x00007ff556f79feb in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Core.so.5
#43 0x00007ff556f81ed6 in QCoreApplication::exec() () at /usr/lib64/libQt5Core.so.5
#44 0x0000000000465f25 in  ()
#45 0x00007ff5565fe6e5 in __libc_start_main () at /lib64/libc.so.6
#46 0x00000000004660d9 in _start ()

Reported using DrKonqi
Comment 1 Leslie Zhai 2017-08-02 03:07:02 UTC
Hi Michael,

Could you use gdb to debug k3b git master https://github.com/KDE/k3b I can not reproduce the issue, thanks!

Regards,
Leslie Zhai - a LLVM developer https://reviews.llvm.org/p/xiangzhai/
Comment 2 Leslie Zhai 2017-08-02 03:08:41 UTC
Cc Mark, could you help Michael to debug gdb? thanks!
Comment 3 Leslie Zhai 2017-08-02 04:58:49 UTC
Cc Dr. Chapatin, he can burn several projects https://bugs.kde.org/show_bug.cgi?id=382488#c0 but no crash.

To Michael,
DrKonqi can not show the detailed backtrace information, please enable -DK3B_DEBUG=ON https://github.com/KDE/k3b/blob/master/INSTALL.txt#L47 then use gdb to bt, thanks!
Comment 4 Mark 2017-08-03 09:11:37 UTC
Hi Michael and g'day again Leslie,

Leslie, I can confirm at least that if main window is hidden when burning, it never re-appears after closing the burning dialog even though k3b is still running. This has always been the case in the Qt5 version (for me).

Michael, here is some info to help make a detailed backtrace. Un-install the openSUSE package before beginning.

Firstly, you'll need to download and compile k3b with debugging information. In a terminal, run the following:

git clone https://github.com/KDE/k3b.git
cd k3b
mkdir build-debug
cd build-debug
cmake -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_C_FLAGS=-ggdb -DCMAKE_CXX_FLAGS=-ggdb -DK3B_DEBUG=on -Wno-dev ..
make -j4
sudo make install

Now, start the debugging session by running:
gdb k3b

When loaded you'll have a prompt (gdb). Type (no quote marks) 'run' to start k3b then use k3b normally until you trigger the segfault. Go back to the (gdb) prompt and type 'backtrace'. Copy the output from this into your bug report. 

Now type 'detach' so that gdb closes the application then type 'quit' to exit gdb.

Mark
Comment 5 Leslie Zhai 2017-08-03 09:24:56 UTC
Hi Mark,

Thanks for your help! and please do me a favor to use gdb debug k3b and paste the bt information, thanks!

Regards,
Leslie Zhai
Comment 6 Leslie Zhai 2017-08-04 01:14:51 UTC
Hi Erwin,

Could you do me a favor to reproduce the issue by gdb, and provide the backtrance information please? thanks!

Regards,
Leslie Zhai
Comment 7 Erwin Lam 2017-08-04 05:54:15 UTC
Leslie,

Please, do not add my e-mail address to other bug reports. I will do that myself if I would be interested. Regarding this bug report, I did not experience the issue nor did I report it.

Regards,
Erwin Lam
Comment 8 Michael Lashkevich 2017-08-04 15:32:22 UTC
I added a -debuginfo package from Packmann repository. A crash appeared on closing k3b this time.

(gdb) backtrace
#0  0x0000000a00000000 in  ()
#1  0x00007ffff1b98d84 in KFileMetaData::Extractor::~Extractor() () at /usr/lib64/libKF5FileMetaData.so.3
#2  0x00007ffff1b98da9 in KFileMetaData::Extractor::~Extractor() () at /usr/lib64/libKF5FileMetaData.so.3
#3  0x00007ffff1b9a41f in KFileMetaData::ExtractorCollection::~ExtractorCollection() () at /usr/lib64/libKF5FileMetaData.so.3
#4  0x00007ffff7a9936e in K3b::AudioDecoder::~AudioDecoder() (this=0x1a41c30, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/plugin/k3baudiodecoder.cpp:90
#5  0x00007ffff7a9936e in K3b::AudioDecoder::~AudioDecoder() (this=0xd90fa0, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/plugin/k3baudiodecoder.cpp:174
#6  0x00007fffcc8b5299 in K3bMadDecoder::~K3bMadDecoder() (this=0xd90fa0, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/plugins/decoder/mp3/k3bmaddecoder.cpp:95
#7  0x00007ffff7af6fc4 in K3b::AudioDoc::decreaseDecoderUsage(K3b::AudioDecoder*) (this=<optimized out>, decoder=0xd90fa0)
    at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiodoc.cpp:1056
#8  0x00007ffff7afb592 in K3b::AudioFile::~AudioFile() (this=0x12b47b0, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiofile.cpp:53
#9  0x00007ffff7afb5b9 in K3b::AudioFile::~AudioFile() (this=0x12b47b0, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiofile.cpp:54
#10 0x00007ffff7aecf25 in K3b::AudioTrack::~AudioTrack() (this=0xaff1f0, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiotrack.cpp:101
#11 0x00007ffff7aed059 in K3b::AudioTrack::~AudioTrack() (this=0xaff1f0, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiotrack.cpp:106
#12 0x00007ffff7af31fe in K3b::AudioDoc::~AudioDoc() (this=0x11fab20, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiodoc.cpp:101
#13 0x00007ffff7af3489 in K3b::AudioDoc::~AudioDoc() (this=0x11fab20, __in_chrg=<optimized out>) at /usr/src/debug/k3b-17.04.3/libk3b/projects/audiocd/k3baudiodoc.cpp:107
#14 0x00000000004867e4 in K3b::MainWindow::queryClose() (this=0xcb02b0) at /usr/src/debug/k3b-17.04.3/src/k3b.cpp:886
#15 0x00007ffff5f90e74 in KMainWindow::closeEvent(QCloseEvent*) () at /usr/lib64/libKF5XmlGui.so.5
#16 0x00007ffff3719c68 in QWidget::event(QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#17 0x00007ffff382a0cb in QMainWindow::event(QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#18 0x00007ffff5f91057 in KMainWindow::event(QEvent*) () at /usr/lib64/libKF5XmlGui.so.5
#19 0x00007ffff5fcdc45 in KXmlGuiWindow::event(QEvent*) () at /usr/lib64/libKF5XmlGui.so.5
#20 0x00007ffff36d7e3c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#21 0x00007ffff36dc49a in QApplication::notify(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#22 0x00007ffff274efd5 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib64/libQt5Core.so.5
#23 0x00007ffff3714fa9 in QWidgetPrivate::close_helper(QWidgetPrivate::CloseMode) () at /usr/lib64/libQt5Widgets.so.5
#24 0x00007ffff3731ea6 in  () at /usr/lib64/libQt5Widgets.so.5
#25 0x00007ffff3734e53 in  () at /usr/lib64/libQt5Widgets.so.5
#26 0x00007ffff36d7e3c in QApplicationPrivate::notify_helper(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#27 0x00007ffff36dc49a in QApplication::notify(QObject*, QEvent*) () at /usr/lib64/libQt5Widgets.so.5
#28 0x00007ffff274efd5 in QCoreApplication::notifyInternal2(QObject*, QEvent*) () at /usr/lib64/libQt5Core.so.5
#29 0x00007ffff2f21e3c in QGuiApplicationPrivate::processCloseEvent(QWindowSystemInterfacePrivate::CloseEvent*) () at /usr/lib64/libQt5Gui.so.5
#30 0x00007ffff2f25e35 in QGuiApplicationPrivate::processWindowSystemEvent(QWindowSystemInterfacePrivate::WindowSystemEvent*) () at /usr/lib64/libQt5Gui.so.5
#31 0x00007ffff2f07eeb in QWindowSystemInterface::sendWindowSystemEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Gui.so.5
#32 0x00007fffe1645bc0 in  () at /usr/lib64/libQt5XcbQpa.so.5
#33 0x00007fffec127134 in g_main_context_dispatch () at /usr/lib64/libglib-2.0.so.0
#34 0x00007fffec127388 in  () at /usr/lib64/libglib-2.0.so.0
#35 0x00007fffec12742c in g_main_context_iteration () at /usr/lib64/libglib-2.0.so.0
#36 0x00007ffff279f31c in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Core.so.5
#37 0x00007ffff274cfeb in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () at /usr/lib64/libQt5Core.so.5
#38 0x00007ffff2754ed6 in QCoreApplication::exec() () at /usr/lib64/libQt5Core.so.5
#39 0x0000000000465f25 in main(int, char**) (argc=1, argv=<optimized out>) at /usr/src/debug/k3b-17.04.3/src/main.cpp:133
Comment 9 Leslie Zhai 2017-08-07 02:00:11 UTC
Git commit 9a289750eec11de8acfb9bf5aea12dcab09ba005 by Leslie Zhai.
Committed on 07/08/2017 at 01:58.
Pushed by lesliezhai into branch 'master'.

Fix SRC_STATE use-after-free issue.

M  +4    -2    libk3b/plugin/k3baudiodecoder.cpp

https://commits.kde.org/k3b/9a289750eec11de8acfb9bf5aea12dcab09ba005
Comment 10 Leslie Zhai 2017-08-07 02:01:04 UTC
Hi Michael,

Thanks for your report! please try my patch https://commits.kde.org/k3b/9a289750eec11de8acfb9bf5aea12dcab09ba005

Regards,
Leslie Zhai
Comment 11 Justin Zobel 2020-12-17 05:30:06 UTC
Thank you for the crash report.

As it has been a while since this was reported, can you please test and confirm if this issue is still occurring or if this bug report can be marked as resolved.

I have set the bug status to "needsinfo" pending your response, please change back to "reported" or "resolved/worksforme" when you respond, thank you.
Comment 12 Bug Janitor Service 2021-01-01 04:37:12 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 13 Bug Janitor Service 2021-01-16 04:36:09 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!