Bug 241405 - Konversation trunk crashes on irc server edit (New network dialog)
Summary: Konversation trunk crashes on irc server edit (New network dialog)
Status: RESOLVED FIXED
Alias: None
Product: konversation
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Arch Linux Linux
: NOR crash
Target Milestone: ---
Assignee: Konversation Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-11 12:16 UTC by Julien Humbert
Modified: 2010-06-11 12:52 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 Julien Humbert 2010-06-11 12:16:51 UTC
Application: konversation (1.3+ #4047)
KDE Platform Version: 4.4.85 (KDE 4.4.85 (KDE 4.5 Beta2))
Qt Version: 4.6.3
Operating System: Linux 2.6.34-ARCH x86_64
Distribution: "Arch Linux - A simple, lightweight linux distribution."

-- Information about the crash:
- What I was doing when the application crashed:
I was adding a new server in the « New Network » dialog, the I wanted to correct the mistyped character with the edit button, then Konversation crashes.

- Custom settings of the application:
Konversation Trunk, build from Git sources

The crash can be reproduced every time.

-- Backtrace:
Application: Konversation (konversation), signal: Aborted
[Current thread is 1 (Thread 0x7f0dcd0cd760 (LWP 8069))]

Thread 2 (Thread 0x7f0db8d36710 (LWP 8070)):
#0  0x00007f0dc83cef23 in poll () from /lib/libc.so.6
#1  0x00007f0dc633f074 in g_main_context_iterate () from /usr/lib/libglib-2.0.so.0
#2  0x00007f0dc633f5ad in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#3  0x00007f0dc9c45886 in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#4  0x00007f0dc9c1c122 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#5  0x00007f0dc9c1c35c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#6  0x00007f0dc9b33bef in QThread::exec() () from /usr/lib/libQtCore.so.4
#7  0x00007f0dc9bfe448 in ?? () from /usr/lib/libQtCore.so.4
#8  0x00007f0dc9b36485 in ?? () from /usr/lib/libQtCore.so.4
#9  0x00007f0dc7038cb0 in start_thread () from /lib/libpthread.so.0
#10 0x00007f0dc83d778d in clone () from /lib/libc.so.6
#11 0x0000000000000000 in ?? ()

Thread 1 (Thread 0x7f0dcd0cd760 (LWP 8069)):
[KCrash Handler]
#6  0x00007f0dc833b515 in raise () from /lib/libc.so.6
#7  0x00007f0dc833c996 in abort () from /lib/libc.so.6
#8  0x00007f0dc9b2e35f in qt_message_output(QtMsgType, char const*) () from /usr/lib/libQtCore.so.4
#9  0x00007f0dc9b2e4ed in ?? () from /usr/lib/libQtCore.so.4
#10 0x00007f0dc9b2e685 in qFatal(char const*, ...) () from /usr/lib/libQtCore.so.4
#11 0x0000000000475539 in QList<Konversation::ServerSettings>::operator[] (this=0x28e9d90, i=-1) at /usr/include/QtCore/qlist.h:447
#12 0x00000000004e8d2f in Konversation::ServerGroupDialog::editServer (this=0x28e9d40) at /home/julroy67/Apps/konversation-git/src/konversation/src/irc/servergroupdialog.cpp:180
#13 0x00000000004e9e44 in Konversation::ServerGroupDialog::qt_metacall (this=0x28e9d40, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=0x7fffd6f23f80)
    at /home/julroy67/Apps/konversation-git/src/build/src/servergroupdialog.moc:95
#14 0x00007f0dc9c30d9f in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/libQtCore.so.4
#15 0x00007f0dc93f2b92 in QAbstractButton::clicked(bool) () from /usr/lib/libQtGui.so.4
#16 0x00007f0dc9144c2b in ?? () from /usr/lib/libQtGui.so.4
#17 0x00007f0dc9145fdb in ?? () from /usr/lib/libQtGui.so.4
#18 0x00007f0dc914624c in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/libQtGui.so.4
#19 0x00007f0dc8dee292 in QWidget::event(QEvent*) () from /usr/lib/libQtGui.so.4
#20 0x00007f0dc8d9e854 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#21 0x00007f0dc8da31ba in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#22 0x00007f0dca6039d6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib/libkdeui.so.5
#23 0x00007f0dc9c1cd3c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4
#24 0x00007f0dc8d9f7a5 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) () from /usr/lib/libQtGui.so.4
#25 0x00007f0dc8e1a3c8 in ?? () from /usr/lib/libQtGui.so.4
#26 0x00007f0dc8e18dc9 in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib/libQtGui.so.4
#27 0x00007f0dc8e3e6b2 in ?? () from /usr/lib/libQtGui.so.4
#28 0x00007f0dc633eb33 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#29 0x00007f0dc633f310 in g_main_context_iterate () from /usr/lib/libglib-2.0.so.0
#30 0x00007f0dc633f5ad in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#31 0x00007f0dc9c4582f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#32 0x00007f0dc8e3e37e in ?? () from /usr/lib/libQtGui.so.4
#33 0x00007f0dc9c1c122 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#34 0x00007f0dc9c1c35c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#35 0x00007f0dc924032e in QDialog::exec() () from /usr/lib/libQtGui.so.4
#36 0x00000000004f01c0 in Konversation::ServerListDialog::slotAdd (this=0x29343a0) at /home/julroy67/Apps/konversation-git/src/konversation/src/irc/serverlistdialog.cpp:147
#37 0x00000000004f1bf4 in Konversation::ServerListDialog::qt_metacall (this=0x29343a0, _c=QMetaObject::InvokeMetaMethod, _id=<value optimized out>, _a=0x7fffd6f25740)
    at /home/julroy67/Apps/konversation-git/src/build/src/serverlistdialog.moc:109
#38 0x00007f0dc9c30d9f in QMetaObject::activate(QObject*, QMetaObject const*, int, void**) () from /usr/lib/libQtCore.so.4
#39 0x00007f0dc93f2b92 in QAbstractButton::clicked(bool) () from /usr/lib/libQtGui.so.4
#40 0x00007f0dc9144c2b in ?? () from /usr/lib/libQtGui.so.4
#41 0x00007f0dc9145fdb in ?? () from /usr/lib/libQtGui.so.4
#42 0x00007f0dc914624c in QAbstractButton::mouseReleaseEvent(QMouseEvent*) () from /usr/lib/libQtGui.so.4
#43 0x00007f0dc8dee292 in QWidget::event(QEvent*) () from /usr/lib/libQtGui.so.4
#44 0x00007f0dc8d9e854 in QApplicationPrivate::notify_helper(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#45 0x00007f0dc8da31ba in QApplication::notify(QObject*, QEvent*) () from /usr/lib/libQtGui.so.4
#46 0x00007f0dca6039d6 in KApplication::notify(QObject*, QEvent*) () from /usr/lib/libkdeui.so.5
#47 0x00007f0dc9c1cd3c in QCoreApplication::notifyInternal(QObject*, QEvent*) () from /usr/lib/libQtCore.so.4
#48 0x00007f0dc8d9f7a5 in QApplicationPrivate::sendMouseEvent(QWidget*, QMouseEvent*, QWidget*, QWidget*, QWidget**, QPointer<QWidget>&, bool) () from /usr/lib/libQtGui.so.4
#49 0x00007f0dc8e1a3c8 in ?? () from /usr/lib/libQtGui.so.4
#50 0x00007f0dc8e18dc9 in QApplication::x11ProcessEvent(_XEvent*) () from /usr/lib/libQtGui.so.4
#51 0x00007f0dc8e3e6b2 in ?? () from /usr/lib/libQtGui.so.4
#52 0x00007f0dc633eb33 in g_main_context_dispatch () from /usr/lib/libglib-2.0.so.0
#53 0x00007f0dc633f310 in g_main_context_iterate () from /usr/lib/libglib-2.0.so.0
#54 0x00007f0dc633f5ad in g_main_context_iteration () from /usr/lib/libglib-2.0.so.0
#55 0x00007f0dc9c4582f in QEventDispatcherGlib::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#56 0x00007f0dc8e3e37e in ?? () from /usr/lib/libQtGui.so.4
#57 0x00007f0dc9c1c122 in QEventLoop::processEvents(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#58 0x00007f0dc9c1c35c in QEventLoop::exec(QFlags<QEventLoop::ProcessEventsFlag>) () from /usr/lib/libQtCore.so.4
#59 0x00007f0dc9c2076b in QCoreApplication::exec() () from /usr/lib/libQtCore.so.4
#60 0x0000000000465d56 in main (argc=1, argv=0x7fffd6f27b78) at /home/julroy67/Apps/konversation-git/src/konversation/src/main.cpp:104

Reported using DrKonqi
Comment 1 Julien Humbert 2010-06-11 12:22:11 UTC
Hmm sorry for the bad english, I forgot to add the steps to reproduce, and there is it :

1. Launch Konqueror
2. Open up the « Server List » dialog, if not opened up at startup
3. Click on the « New » button
4. On the « New Network » dialog, click the « Add » button for the server (not the auto join channels)
5. Add a server (happens with all type of text)
6. Then when it's added, directly after click on edit
7. Konversation crashes
Comment 2 Eike Hein 2010-06-11 12:52:26 UTC
commit d557244a7019c146e71802aea2a8b9c1a14e09eb
Author: Eike Hein <hein@kde.org>
Date:   Fri Jun 11 12:48:05 2010 +0200

    Fix regressions from 9e28e6e1.
    
    BUG:241405

diff --git a/ChangeLog b/ChangeLog
index 8c08ba7..1e8877d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -4,6 +4,14 @@ Changes since 1.3:
   automatic reconnect in the event of connection failure as well.
 * The '/disconnect' and '/reconnect' commands now take optional quit message
   parameters.
+* Fixed crashes when pressing the "Edit" buttons below the server or
+  channel lists in the "New Network"/"Edit Network" dialogs after adding
+  a new server or channel and there was no item selected before in the re-
+  spective list.
+* Fixed bugs causing the "Edit" buttons below the server or channel lists
+  in the "New Network"/"Edit Network" dialogs to edit the previously selec-
+  ted list items rather than the ones shown as selected after adding a new
+  server or channel.
 
 
 Changes from 1.3-beta1 to 1.3:
diff --git a/src/irc/servergroupdialog.cpp b/src/irc/servergroupdialog.cpp
index f49fb4d..b7e3504 100644
--- a/src/irc/servergroupdialog.cpp
+++ b/src/irc/servergroupdialog.cpp
@@ -164,7 +164,7 @@ namespace Konversation
         {
             ServerSettings server = dlg->serverSettings();
             m_mainWidget->m_serverLBox->addItem(server.host());
-            m_mainWidget->m_serverLBox->item(m_mainWidget->m_serverLBox->count() - 1)->setSelected(true);
+            m_mainWidget->m_serverLBox->setCurrentItem(m_mainWidget->m_serverLBox->item(m_mainWidget->m_serverLBox->count() - 1));
             m_serverList.append(server);
         }
         delete dlg;
@@ -287,7 +287,7 @@ namespace Konversation
         {
             ChannelSettings channel = dlg->channelSettings();
             m_mainWidget->m_channelLBox->addItem(channel.name());
-            m_mainWidget->m_channelLBox->item(m_mainWidget->m_channelLBox->count() - 1)->setSelected(true);
+            m_mainWidget->m_channelLBox->setCurrentItem(m_mainWidget->m_channelLBox->item(m_mainWidget->m_channelLBox->count() - 1));
             m_channelList.append(channel);
         }
         delete dlg;