diff options
author | Berthold Stoeger <bstoeger@mail.tuwien.ac.at> | 2021-02-12 17:52:31 +0100 |
---|---|---|
committer | Dirk Hohndel <dirk@hohndel.org> | 2021-02-17 07:26:55 -0800 |
commit | 03a7e65cf02602e95ac58b217cc9364546361d2f (patch) | |
tree | df76bb46756ce14ee8ecd12289921e956e3b9243 /core/planner.c | |
parent | 8103e947aa80da275afe692bc19fa7bb88ccd033 (diff) | |
download | subsurface-03a7e65cf02602e95ac58b217cc9364546361d2f.tar.gz |
planner: pass in_planner argument to clear_deco()
To remove reliance on global state, pass an "in_planner" argument
to clear_deco(). Thus, calls to in_planner() can be removed.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/planner.c')
-rw-r--r-- | core/planner.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/planner.c b/core/planner.c index e5479b6fd..973b6ee5f 100644 --- a/core/planner.c +++ b/core/planner.c @@ -678,7 +678,7 @@ bool plan(struct deco_state *ds, struct diveplan *diveplan, struct dive *dive, i if (!diveplan->surface_pressure) diveplan->surface_pressure = SURFACE_PRESSURE; dive->surface_pressure.mbar = diveplan->surface_pressure; - clear_deco(ds, dive->surface_pressure.mbar / 1000.0); + clear_deco(ds, dive->surface_pressure.mbar / 1000.0, true); ds->max_bottom_ceiling_pressure.mbar = ds->first_ceiling_pressure.mbar = 0; create_dive_from_plan(diveplan, dive, is_planner); |