aboutsummaryrefslogtreecommitdiffstats
path: root/qt-ui/divelistview.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/divelistview.cpp')
-rw-r--r--qt-ui/divelistview.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/qt-ui/divelistview.cpp b/qt-ui/divelistview.cpp
index c1dde082b..b905b32be 100644
--- a/qt-ui/divelistview.cpp
+++ b/qt-ui/divelistview.cpp
@@ -431,9 +431,9 @@ void DiveListView::merge_trip(const QModelIndex &a, int offset)
if (trip_a == trip_b || !trip_a || !trip_b)
return;
- if (!trip_a->location)
+ if (!trip_a->location && trip_b->location)
trip_a->location = strdup(trip_b->location);
- if (!trip_a->notes)
+ if (!trip_a->notes && trip_b->notes)
trip_a->notes = strdup(trip_b->notes);
while (trip_b->dives)
add_dive_to_trip(trip_b->dives, trip_a);