mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
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>
This commit is contained in:
parent
8103e947aa
commit
03a7e65cf0
4 changed files with 6 additions and 6 deletions
|
@ -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);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue