aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--subsurface-core/divelist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/subsurface-core/divelist.c b/subsurface-core/divelist.c
index bac63ed97..99e09eab6 100644
--- a/subsurface-core/divelist.c
+++ b/subsurface-core/divelist.c
@@ -866,7 +866,7 @@ struct dive *merge_two_dives(struct dive *a, struct dive *b)
// renumber dives from merged one in advance by difference between
// merged dives numbers. Do not renumber if actual number is zero.
for (; j < dive_table.nr; j++)
- if (!dive_table.dives[j]->number == 0)
+ if (dive_table.dives[j]->number != 0)
dive_table.dives[j]->number -= factor;
mark_divelist_changed(true);