projects
/
quassel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
3b30525
)
common: Avoid crash on SignalProxy destruction
author
Manuel Nickschas
<sputnick@quassel-irc.org>
Tue, 25 Sep 2018 22:47:14 +0000
(
00:47
+0200)
committer
Manuel Nickschas
<sputnick@quassel-irc.org>
Mon, 1 Oct 2018 17:06:49 +0000
(19:06 +0200)
Since SignalProxy itself attaches a slot, it will try to detach
itself on destruction, leading to a crash. Avoid this by checking
for self-detachment.
src/common/signalproxy.cpp
patch
|
blob
|
history
diff --git
a/src/common/signalproxy.cpp
b/src/common/signalproxy.cpp
index
3ac73bc
..
5e5f59d
100644
(file)
--- a/
src/common/signalproxy.cpp
+++ b/
src/common/signalproxy.cpp
@@
-475,8
+475,11
@@
void SignalProxy::synchronize(SyncableObject *obj)
void SignalProxy::detachObject(QObject *obj)
{
- detachSignals(obj);
- detachSlots(obj);
+ // Don't try to connect SignalProxy from itself on shutdown
+ if (obj != this) {
+ detachSignals(obj);
+ detachSlots(obj);
+ }
}