summaryrefslogtreecommitdiffhomepage
path: root/spline-widget/spline-widget.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2016-08-21 22:27:54 +0200
committerStanislaw Halik <sthalik@misaki.pl>2016-08-23 00:05:15 +0200
commitf2f583797d1723b443bf370ec5b7b133ad83b9fa (patch)
tree123932aa37383cb43307894610c6cd82f0ef3f46 /spline-widget/spline-widget.cpp
parent321501ad58dad2688bde42992b61adcda5a313e0 (diff)
spline-widget: disconnect "recomputed" in dtor
In case mem<settings> is still used elsewhere we still have a use-after-free otherwise.
Diffstat (limited to 'spline-widget/spline-widget.cpp')
-rw-r--r--spline-widget/spline-widget.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/spline-widget/spline-widget.cpp b/spline-widget/spline-widget.cpp
index 54107bbe..6e3a95b3 100644
--- a/spline-widget/spline-widget.cpp
+++ b/spline-widget/spline-widget.cpp
@@ -29,6 +29,12 @@ spline_widget::spline_widget(QWidget *parent) :
setMouseTracking(true);
}
+spline_widget::~spline_widget()
+{
+ if (connection)
+ QObject::disconnect(connection);
+}
+
void spline_widget::setConfig(spline* spl)
{
if (spl != _config)