From 046954a05b92f5b8083fc960f271e4299101cbd2 Mon Sep 17 00:00:00 2001 From: wmayer Date: Sat, 18 Nov 2017 18:07:00 +0100 Subject: [PATCH] fix coverity issues --- src/Mod/Part/Gui/TaskAttacher.cpp | 6 +++++- src/Mod/PartDesign/Gui/TaskFeaturePick.cpp | 2 +- src/Mod/Sketcher/Gui/CommandCreateGeo.cpp | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/Mod/Part/Gui/TaskAttacher.cpp b/src/Mod/Part/Gui/TaskAttacher.cpp index e616dd9976..87aaefa9f3 100644 --- a/src/Mod/Part/Gui/TaskAttacher.cpp +++ b/src/Mod/Part/Gui/TaskAttacher.cpp @@ -214,7 +214,11 @@ TaskAttacher::TaskAttacher(Gui::ViewProviderDocumentObject *ViewProvider,QWidget TaskAttacher::~TaskAttacher() { - visibilityAutomation(false); + try { + visibilityAutomation(false); + } + catch (...) { + } connectDelObject.disconnect(); delete ui; diff --git a/src/Mod/PartDesign/Gui/TaskFeaturePick.cpp b/src/Mod/PartDesign/Gui/TaskFeaturePick.cpp index 177b259931..f9b43fcf78 100644 --- a/src/Mod/PartDesign/Gui/TaskFeaturePick.cpp +++ b/src/Mod/PartDesign/Gui/TaskFeaturePick.cpp @@ -507,7 +507,7 @@ TaskDlgFeaturePick::~TaskDlgFeaturePick() //do the work now as before in accept() the dialog is still open, hence the work //function could not open another dialog if (accepted) { - workFunction(pick->buildFeatures()); + try { workFunction(pick->buildFeatures()); } catch (...) {} } else if (abortFunction) { // Get rid of the TaskFeaturePick before the TaskDialog dtor does. The diff --git a/src/Mod/Sketcher/Gui/CommandCreateGeo.cpp b/src/Mod/Sketcher/Gui/CommandCreateGeo.cpp index 96dbf25038..b1dd697b15 100644 --- a/src/Mod/Sketcher/Gui/CommandCreateGeo.cpp +++ b/src/Mod/Sketcher/Gui/CommandCreateGeo.cpp @@ -6060,6 +6060,7 @@ public: , EditCurve(2) , BaseGeoId(-1) , ExtendFromStart(false) + , SavedExtendFromStart(false) , Increment(0) { }