summaryrefslogtreecommitdiffstats
path: root/qt-ui/diveplanner.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/diveplanner.cpp')
-rw-r--r--qt-ui/diveplanner.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp
index a8f45d91f..1aaf5aa7d 100644
--- a/qt-ui/diveplanner.cpp
+++ b/qt-ui/diveplanner.cpp
@@ -195,6 +195,16 @@ void DivePlannerGraphics::createDecoStops()
scene()->addItem(item);
lines << item;
}
+
+ deleteTemporaryDivePlan(diveplan.dp);
+}
+
+void DivePlannerGraphics::deleteTemporaryDivePlan(divedatapoint* dp)
+{
+ if (!dp)
+ return;
+ deleteTemporaryDivePlan(dp->next);
+ free(dp);
}
void DivePlannerGraphics::resizeEvent(QResizeEvent* event)