Opened 8 years ago

Closed 8 years ago

#3171 closed defect (fixed)

Vidalia 0.3.0: Segfault when restarting Tor without starting it first

Reported by: fk Owned by: chiiph
Priority: Medium Milestone: Vidalia: 0.3.x
Component: Archived/Vidalia Version: Vidalia: 0.3.0-alpha
Severity: Keywords: Vidalia
Cc: Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

The menu entry Tor/Restart causes a segfault when
Vidalia isn't actually connected to Tor:

(gdb) r
Starting program: /usr/local/bin/vidalia --loglevel notice
[New LWP 100689]
[New Thread 805807400 (LWP 100689/initial thread)]
May 13 17:23:10.057 [notice] Resetting UI translation to English default.
May 13 17:23:10.399 [notice] Vidalia 0.3.0 using Qt 4.7.2
May 13 17:23:11.397 [notice] QtWarningMsg: QSystemTrayIcon::setVisible: No Icon set
May 13 17:23:11.428 [notice] QtWarningMsg: Application asked to unregister timer 0x3600000b which is not registered in this thread. Fix application.
[New Thread 805809000 (LWP 100942/vidalia)]

Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 805807400 (LWP 100689/initial thread)]
0x0000000802614723 in QString::operator= (this=0x0, other=@0x7fffffffacd0) at tools/qstring.cpp:1358
1358    tools/qstring.cpp: No such file or directory.
        in tools/qstring.cpp
(gdb) where
!#0  0x0000000802614723 in QString::operator= (this=0x0, other=@0x7fffffffacd0) at tools/qstring.cpp:1358
!#1  0x0000000000511e85 in TorControl::stop (this=0x805896ac0, errmsg=0x0) at /usr/obj/usr/ports/net-mgmt/vidalia-devel/work/vidalia-0.3.0/src/torcontrol/TorControl.cpp:137
!#2  0x00000000004a48be in MainWindow::restart (this=0x7fffffffd100) at /usr/obj/usr/ports/net-mgmt/vidalia-devel/work/vidalia-0.3.0/src/vidalia/MainWindow.cpp:1406
!#3  0x00000000004b0fad in MainWindow::qt_metacall (this=0x7fffffffd100, _c=QMetaObject::InvokeMetaMethod, _id=3, _a=0x7fffffffaf50)
    at /usr/obj/usr/ports/net-mgmt/vidalia-devel/work/vidalia-0.3.0/src/vidalia/moc_MainWindow.cxx:144
!#4  0x00000008026f28d2 in QMetaObject::metacall (object=0x7fffffffd100, cl=QMetaObject::InvokeMetaMethod, idx=37, argv=0x7fffffffaf50) at kernel/qmetaobject.cpp:237
!#5  0x00000008027081fd in QMetaObject::activate (sender=0x805a8bc00, m=0x801e2c9a0, local_signal_index=1, argv=0x7fffffffaf50) at kernel/qobject.cpp:3278
!#6  0x00000008010a9991 in QAction::triggered (this=0x805a8bc00, _t1=false) at moc_qaction.cpp:263
!#7  0x00000008010ab5ac in QAction::activate (this=0x805a8bc00, event=QAction::Trigger) at kernel/qaction.cpp:1257
[...]

Child Tickets

Attachments (1)

vidalia-0.3.0--Prevent-a-SEGFAULT-when-Tor-is-restarted-without-bei.patch (921 bytes) - added by fk 8 years ago.
Patch that prevents the crashes for me

Download all attachments as: .zip

Change History (3)

Changed 8 years ago by fk

Patch that prevents the crashes for me

comment:1 Changed 8 years ago by fk

Simply greying out the menu entry when Vidalia isn't connected
to Tor might work, too, but I'm not sure if there aren't
other ways to reach MainWindow::restart() without Vidalia
being connected to Tor.

comment:2 Changed 8 years ago by chiiph

Milestone: Vidalia-0.3.X
Resolution: fixed
Status: newclosed
Version: Vidalia: 0.3.0-alpha

The fix is in 20eff7c2c0158b29e01a4d7fc6a54eb6093326de. This will be in 0.3.1
Thanks for reporting!

Note: See TracTickets for help on using tickets.