summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Rick Walsh <rickmwalsh@gmail.com>2015-06-23 23:04:02 +1000
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-06-23 06:15:07 -0700
commit228eb6ce27ff67d719282457e6afca186071ff74 (patch)
tree4975751ded0ed9c7a216a9859d80e42907148fac
parent094264014dc476942bd2cbf7709543155dad7bf4 (diff)
downloadsubsurface-228eb6ce27ff67d719282457e6afca186071ff74.tar.gz
Fix gaschange_after definition
Previously gaschange_after was never being set back to false. Now it will be. Signed-off-by: Rick Walsh <rickmwalsh@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r--planner.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/planner.c b/planner.c
index 227125016..fc4275b4b 100644
--- a/planner.c
+++ b/planner.c
@@ -594,8 +594,7 @@ static void add_plan_to_notes(struct diveplan *diveplan, struct dive *dive, bool
continue;
len = strlen(buffer);
- if (nextdp && (gasmix_distance(&gasmix, &newgasmix) || dp->setpoint != nextdp->setpoint))
- gaschange_after = true;
+ gaschange_after = (nextdp && (gasmix_distance(&gasmix, &newgasmix) || dp->setpoint != nextdp->setpoint));
gaschange_before = (gasmix_distance(&lastprintgasmix, &gasmix) || lastprintsetpoint != dp->setpoint);
if (plan_verbatim) {
if (dp->depth != lastprintdepth) {