summaryrefslogtreecommitdiffstats
path: root/qt-ui/maintab.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/maintab.cpp')
-rw-r--r--qt-ui/maintab.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/qt-ui/maintab.cpp b/qt-ui/maintab.cpp
index f9aeabd0d..b84b27c67 100644
--- a/qt-ui/maintab.cpp
+++ b/qt-ui/maintab.cpp
@@ -868,6 +868,9 @@ void MainTab::updateDiveSite(int divenr)
}
uint32_t pickedUuid = ui.location->currDiveSiteUuid();
+ if (pickedUuid == 0)
+ return;
+
const uint32_t origUuid = cd->dive_site_uuid;
struct dive_site *origDs = get_dive_site_by_uuid(origUuid);
struct dive_site *newDs = NULL;