summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/profile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/profile.c b/core/profile.c
index 631aaa8b8..a1d0c45f0 100644
--- a/core/profile.c
+++ b/core/profile.c
@@ -1036,7 +1036,7 @@ void calculate_deco_information(struct dive *dive, struct divecomputer *dc, stru
// Use the point where the ceiling clears as the end of deco phase for CVA calculations
if (current_ceiling > 0)
time_clear_ceiling = 0;
- else if (time_clear_ceiling == 0)
+ else if (time_clear_ceiling == 0 && t1 > time_deep_ceiling)
time_clear_ceiling = t1;
}
}