aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Stefan Fuchs <sfuchs@gmx.de>2017-10-03 11:12:35 +0200
committerGravatar Robert C. Helling <helling@atdotde.de>2017-10-16 18:23:27 +0200
commit4fa576526f0152327ddf4b0381e79adc8debd22e (patch)
tree20f5cd93100ff67fc5dda4be9515d0ecec63efe3
parentbfe52f66892c9d015d717c8c64f60e36704ab182 (diff)
downloadsubsurface-4fa576526f0152327ddf4b0381e79adc8debd22e.tar.gz
Planner creating dive from plan: No pressure for 1st sample with new gas
In the planner when a dive is created from the diveplan every first sample with a new gas shouldn't have a pressure value added. Otherwise the interpolation code for the pressure graph in the profile will draw the pressure graph incorrectly. Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
-rw-r--r--core/planner.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/core/planner.c b/core/planner.c
index 5a50130fd..338b89cd2 100644
--- a/core/planner.c
+++ b/core/planner.c
@@ -330,8 +330,6 @@ static void create_dive_from_plan(struct diveplan *diveplan, struct dive *dive,
sample->depth = lastdepth;
sample->manually_entered = dp->entered;
sample->sac.mliter = dp->entered ? prefs.bottomsac : prefs.decosac;
- if (track_gas && cyl->type.workingpressure.mbar)
- sample->pressure[0].mbar = cyl->sample_end.mbar;
finish_sample(dc);
lastcylid = dp->cylinderid;
}