Bug 247533 - Mailformated entry in /etc/apt/sources list results in muon crash
Summary: Mailformated entry in /etc/apt/sources list results in muon crash
Status: RESOLVED FIXED
Alias: None
Product: muon
Classification: Applications
Component: libqapt (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR crash
Target Milestone: ---
Assignee: Jonathan Thomas
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-08-12 17:29 UTC by Dirk Sarpe
Modified: 2010-08-12 19:36 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In: 1.0.1


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dirk Sarpe 2010-08-12 17:29:20 UTC
Application: muon (1.0)
KDE Platform Version: 4.5.00 (KDE 4.5.0)
Qt Version: 4.7.0
Operating System: Linux 2.6.32-24-generic x86_64
Distribution: Ubuntu 10.04.1 LTS

-- Information about the crash:
I added the following entry to /etc/apt/sources.list (missing u in ubuntu)
deb http://archive.ubuntu.com/buntu lucid

On startup muon crashed. An aptitude update tells me that the entry is mailformated. After commenting the line out muon starts again.

OT: Really a nice application, very straightforward to use. Menu entries are where I was suspecting them. Thanks. :)

The crash can be reproduced every time.

-- Backtrace:
Application: Muon Package Manager (muon), signal: Segmentation fault
[KCrash Handler]
#6  pkgDepCache::operator pkgCache& (this=<value optimized out>) at /usr/include/apt-pkg/depcache.h:331
#7  QApt::Backend::reloadCache (this=<value optimized out>) at /build/buildd/qapt-1.0/src/backend.cpp:133
#8  0x00007efff10db350 in QApt::Backend::init (this=0x1f85d20) at /build/buildd/qapt-1.0/src/backend.cpp:118
#9  0x00000000004163fa in MuonMainWindow::initObject (this=0x1f71510) at /build/buildd/muon-1.0/src/MuonMainWindow.cpp:51
#10 0x000000000041a2f9 in MainWindow::initObject (this=0x20) at /build/buildd/muon-1.0/src/MainWindow.cpp:119
#11 0x000000000041c3dc in MainWindow::qt_metacall (this=0x1f71510, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=0x7fff922281f0)
    at /build/buildd/muon-1.0/obj-x86_64-linux-gnu/src/MainWindow.moc:105
#12 0x00007efff01e37a7 in QMetaObject::activate (sender=0x22dc6c0, m=<value optimized out>, local_signal_index=<value optimized out>, argv=0x226d2be) at kernel/qobject.cpp:3280
#13 0x00007efff01e897f in QSingleShotTimer::timerEvent (this=0x22dc6c0) at kernel/qtimer.cpp:308
#14 0x00007efff01dd599 in QObject::event (this=0x22dc6c0, e=0x0) at kernel/qobject.cpp:1183
#15 0x00007effef31fcdc in QApplicationPrivate::notify_helper (this=0x1e545a0, receiver=0x22dc6c0, e=0x7fff92228950) at kernel/qapplication.cpp:4389
#16 0x00007effef3257cd in QApplication::notify (this=0x7fff92228ca0, receiver=0x22dc6c0, e=0x7fff92228950) at kernel/qapplication.cpp:4270
#17 0x00007efff1ef8eb6 in KApplication::notify (this=0x7fff92228ca0, receiver=0x22dc6c0, event=0x7fff92228950) at ../../kdeui/kernel/kapplication.cpp:310
#18 0x00007efff01cba8c in QCoreApplication::notifyInternal (this=0x7fff92228ca0, receiver=0x22dc6c0, event=0x7fff92228950) at kernel/qcoreapplication.cpp:732
#19 0x00007efff01fb0b2 in QCoreApplication::sendEvent (this=0x1e59770) at ../../include/QtCore/../../src/corelib/kernel/qcoreapplication.h:215
#20 QTimerInfoList::activateTimers (this=0x1e59770) at kernel/qeventdispatcher_unix.cpp:602
#21 0x00007efff01f7e94 in timerSourceDispatch (source=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:184
#22 0x00007effe9f0c8c2 in g_main_context_dispatch () from /lib/libglib-2.0.so.0
#23 0x00007effe9f10748 in ?? () from /lib/libglib-2.0.so.0
#24 0x00007effe9f108fc in g_main_context_iteration () from /lib/libglib-2.0.so.0
#25 0x00007efff01f7b83 in QEventDispatcherGlib::processEvents (this=0x1e2fbf0, flags=<value optimized out>) at kernel/qeventdispatcher_glib.cpp:412
#26 0x00007effef3d17ee in QGuiEventDispatcherGlib::processEvents (this=0x20, flags=<value optimized out>) at kernel/qguieventdispatcher_glib.cpp:204
#27 0x00007efff01ca7b2 in QEventLoop::processEvents (this=<value optimized out>, flags=) at kernel/qeventloop.cpp:149
#28 0x00007efff01cab9c in QEventLoop::exec (this=0x7fff92228bf0, flags=) at kernel/qeventloop.cpp:201
#29 0x00007efff01cec4b in QCoreApplication::exec () at kernel/qcoreapplication.cpp:1009
#30 0x000000000041623c in main (argc=<value optimized out>, argv=<value optimized out>) at /build/buildd/muon-1.0/src/main.cpp:54

Reported using DrKonqi
Comment 1 Jonathan Thomas 2010-08-12 19:11:43 UTC
SVN commit 1162786 by jmthomas:

Emit an error and do not attempt to continue initialization if the cache cannot be opened.
Muon still needs to give better details as to what the error exactly is, but it should not crash any more.
BUG:247533
FIXED-IN:1.0.1


 M  +4 -1      backend.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1162786
Comment 2 Jonathan Thomas 2010-08-12 19:21:53 UTC
SVN commit 1162789 by jmthomas:

Errors can occur during backend initialization, so connect error handling connections before attempting to init
Also, quit after the error messagebox is closed by the user in the case of an InitError. Muon will be an empty shell in the event of an init error.
Error details on the todo. I'll try to find a way to present them without breaking string freeze, otherwise better details will have to wait until 1.1

CCBUG:247533


 M  +2 -1      MuonMainWindow.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1162789
Comment 3 Jonathan Thomas 2010-08-12 19:35:20 UTC
SVN commit 1162795 by jmthomas:

Send the internal error message as the details in the event of an InitError

CCBUG:247533


 M  +7 -1      backend.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1162795
Comment 4 Jonathan Thomas 2010-08-12 19:36:40 UTC
SVN commit 1162796 by jmthomas:

Display details for InitErrors now that LibQApt gives them to us. (No string changes; bonus!)
I consider this issue now all the way resolved.

CCBUG:247533


 M  +4 -2      MuonMainWindow.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1162796