Bug 353068 - Crash in KNotification::flags, seemingly stack-smashing related
Summary: Crash in KNotification::flags, seemingly stack-smashing related
Status: RESOLVED DUPLICATE of bug 348414
Alias: None
Product: frameworks-knotifications
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR crash
Target Milestone: ---
Assignee: Martin Klapetek
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-23 00:37 UTC by A. Wilcox (awilfox)
Modified: 2015-09-23 04:13 UTC (History)
1 user (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 A. Wilcox (awilfox) 2015-09-23 00:37:07 UTC
Tried to save a file in Kate.  It had tried to warn me that I was saving "over" a changed file (which I guess is true, because I switched git branches, but i was okay with that).

Instead of having that warning, or having my file saved, I was greeted with a coredump.


Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007f5b545fdb14 in KNotification::flags (this=this@entry=0x28e6900) at /var/tmp/portage/kde-frameworks/knotifications-5.13.0/work/knotifications-5.13.0/src/knotification.cpp:233
233         return d->flags;
[Current thread is 1 (Thread 0x7f5b4e82e7c0 (LWP 7993))]
(gdb) bt
#0  0x00007f5b545fdb14 in KNotification::flags (this=this@entry=0x28e6900) at /var/tmp/portage/kde-frameworks/knotifications-5.13.0/work/knotifications-5.13.0/src/knotification.cpp:233
#1  0x00007f5b5461ac97 in NotifyByAudio::onAudioFinished (this=0x36d87a0) at /var/tmp/portage/kde-frameworks/knotifications-5.13.0/work/knotifications-5.13.0/src/notifybyaudio.cpp:140
#2  0x00007f5b54620a05 in NotifyByAudio::qt_static_metacall (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>)
    at /var/tmp/portage/kde-frameworks/knotifications-5.13.0/work/knotifications-5.13.0_build/src/moc_notifybyaudio.cpp:82
#3  0x00007f5b555cc3e8 in QMetaObject::activate (sender=0x38f2da0, signalOffset=<optimized out>, local_signal_index=local_signal_index@entry=6, argv=argv@entry=0x0) at kernel/qobject.cpp:3717
#4  0x00007f5b555cca87 in QMetaObject::activate (sender=<optimized out>, m=m@entry=0x7f5b51a05000 <Phonon::MediaObject::staticMetaObject>, local_signal_index=local_signal_index@entry=6, argv=argv@entry=0x0)
    at kernel/qobject.cpp:3582
#5  0x00007f5b519d6953 in Phonon::MediaObject::finished (this=<optimized out>) at /var/tmp/portage/media-libs/phonon-4.8.3-r1/work/phonon-4.8.3-qt5/phonon/moc_mediaobject.cpp:421
#6  0x00007f5b519d90d5 in Phonon::MediaObject::qt_static_metacall (_o=<optimized out>, _c=<optimized out>, _id=<optimized out>, _a=<optimized out>)
    at /var/tmp/portage/media-libs/phonon-4.8.3-r1/work/phonon-4.8.3-qt5/phonon/moc_mediaobject.cpp:182
#7  0x00007f5b555cd296 in QObject::event (this=0x38f2da0, e=<optimized out>) at kernel/qobject.cpp:1245
#8  0x00007f5b55ec986c in QApplicationPrivate::notify_helper (this=this@entry=0x1c0a7f0, receiver=receiver@entry=0x38f2da0, e=e@entry=0x2ffc330) at kernel/qapplication.cpp:3720
#9  0x00007f5b55ece680 in QApplication::notify (this=0x7fff048f98f0, receiver=0x38f2da0, e=0x2ffc330) at kernel/qapplication.cpp:3503
#10 0x00007f5b5559b95d in QCoreApplication::notifyInternal (this=0x7fff048f98f0, receiver=0x38f2da0, event=event@entry=0x2ffc330) at kernel/qcoreapplication.cpp:935
#11 0x00007f5b5559d89f in QCoreApplication::sendEvent (event=0x2ffc330, receiver=<optimized out>) at kernel/qcoreapplication.h:228
#12 QCoreApplicationPrivate::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0, data=0x1c00dd0) at kernel/qcoreapplication.cpp:1552
#13 0x00007f5b5559df08 in QCoreApplication::sendPostedEvents (receiver=receiver@entry=0x0, event_type=event_type@entry=0) at kernel/qcoreapplication.cpp:1410
#14 0x00007f5b555f5ae3 in postEventSourceDispatch (s=0x1c48ce0) at kernel/qeventdispatcher_glib.cpp:271
#15 0x00007f5b525d09c4 in g_main_dispatch (context=0x7f5b48002450) at /var/tmp/portage/dev-libs/glib-2.44.1/work/glib-2.44.1/glib/gmain.c:3122
#16 g_main_context_dispatch (context=context@entry=0x7f5b48002450) at /var/tmp/portage/dev-libs/glib-2.44.1/work/glib-2.44.1/glib/gmain.c:3737
#17 0x00007f5b525d0c18 in g_main_context_iterate (context=context@entry=0x7f5b48002450, block=block@entry=1, dispatch=dispatch@entry=1, self=<optimized out>)
    at /var/tmp/portage/dev-libs/glib-2.44.1/work/glib-2.44.1/glib/gmain.c:3808
#18 0x00007f5b525d0cbc in g_main_context_iteration (context=0x7f5b48002450, may_block=1) at /var/tmp/portage/dev-libs/glib-2.44.1/work/glib-2.44.1/glib/gmain.c:3869
#19 0x00007f5b555f4f2c in QEventDispatcherGlib::processEvents (this=0x1c3d4d0, flags=...) at kernel/qeventdispatcher_glib.cpp:418
#20 0x00007f5b555997eb in QEventLoop::exec (this=this@entry=0x7fff048f9620, flags=..., flags@entry=...) at kernel/qeventloop.cpp:204
#21 0x00007f5b555a123f in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1188
#22 0x00007f5b559cc05c in QGuiApplication::exec () at kernel/qguiapplication.cpp:1507
#23 0x00007f5b55ec5f25 in QApplication::exec () at kernel/qapplication.cpp:2956
#24 0x00007f5b585015ae in kdemain (argc=2, argv=<optimized out>) at /var/tmp/portage/kde-apps/kate-15.08.0/work/kate-15.08.0/kate/src/main.cpp:439
#25 0x00007f5b57fe1855 in __libc_start_main (main=0x400700 <main(int, char**)>, argc=2, argv=0x7fff048f9aa8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fff048f9a98)
    at libc-start.c:289
#26 0x0000000000400739 in _start ()
(gdb) p d
$1 = (KNotification::Private * const) 0x20


I will keep the coredump file around if it will help.

Reproducible: Sometimes

Steps to Reproduce:
1. Open a file versioned in a Git repository using Kate.
2. Switch branches, or git stash then git stash pop.
3. Click Save.
4. Be unlucky.

Actual Results:  
Kate crashed in KNotification::flags, with the backtrace shown above.

Expected Results:  
A warning should be shown that the file has changed on disk and a confirmation that I want to overwrite the file.
Comment 1 Martin Klapetek 2015-09-23 01:23:20 UTC
Thanks for the report

Please update your frameworks version to 5.13, thanks.

*** This bug has been marked as a duplicate of bug 348414 ***
Comment 2 A. Wilcox (awilfox) 2015-09-23 03:35:17 UTC
(from comment #0)
> /var/tmp/portage/kde-frameworks/knotifications-5.13.0/work/knotifications-5.
> 13.0/src/knotification.cpp:233

> knotifications-5.13.0

I noticed the similarity to bug 348414, but either it wasn't fixed in 5.13, or this is a new issue.

[I] kde-frameworks/knotifications
     Installed versions:  5.13.0(5)(15:42:25 29/08/15)(X dbus nls -debug -doc)

Is there any further information I can provide to assist?
Comment 3 Martin Klapetek 2015-09-23 03:43:04 UTC
It is in fact the same crash and as such should be reopened in the original report, if still present.

That said, what distro are you running?

*** This bug has been marked as a duplicate of bug 348414 ***
Comment 4 A. Wilcox (awilfox) 2015-09-23 04:13:01 UTC
I am running Gentoo Linux, and okay.  I will report my information on the other bug.