diff options
author | Denis Shienkov <denis.shienkov@gmail.com> | 2015-09-11 12:32:43 +0300 |
---|---|---|
committer | Denis Shienkov <denis.shienkov@gmail.com> | 2015-09-11 12:43:59 +0000 |
commit | 69ee9cd918e4e2527fc26b44aed06162cff0c5d7 (patch) | |
tree | 8c1b873c3946281b6a876de96ef33238cfaacc1f /src/plugins/canbus/peakcan/peakcanbackend.cpp | |
parent | 24c96d1e5c06bcae05f66ad4603dc77fe5bc52ed (diff) |
PeakCan: Use the direct deletion of write notifier
... instead of deffered deletion with deleteLater().
Change-Id: Ida8f4dd5010ee4c7e836ad45fa16716e39588d04
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Diffstat (limited to 'src/plugins/canbus/peakcan/peakcanbackend.cpp')
-rw-r--r-- | src/plugins/canbus/peakcan/peakcanbackend.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/plugins/canbus/peakcan/peakcanbackend.cpp b/src/plugins/canbus/peakcan/peakcanbackend.cpp index ab8f01d..6c5bc51 100644 --- a/src/plugins/canbus/peakcan/peakcanbackend.cpp +++ b/src/plugins/canbus/peakcan/peakcanbackend.cpp @@ -225,8 +225,10 @@ void PeakCanBackendPrivate::close() enableWriteNotification(false); disableReadNotification(); - if (outgoingEventNotifier) - outgoingEventNotifier->deleteLater(); + if (outgoingEventNotifier) { + delete outgoingEventNotifier; + outgoingEventNotifier = Q_NULLPTR; + } if (TPCANStatus st = ::CAN_Uninitialize(channelIndex) != PCAN_ERROR_OK) emit q->setError(systemErrorString(st), QCanBusDevice::ConnectionError); |