mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Use get_cylinder_index in per_cylinder_mean_depth
Use get_cylinder_index that handles SAMPLE_EVENT_GASCHANGE and SAMPLE_EVENT_GASCHANGE2. This also removes the need for a special case where get_gasidx returns -1, because get_cylinder_index always returns the "closest" gas that it finds. Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
51345e4ad8
commit
f6b29d093f
3 changed files with 3 additions and 6 deletions
|
@ -553,7 +553,7 @@ static void fill_missing_tank_pressures(struct dive *dive, struct plot_info *pi,
|
|||
}
|
||||
}
|
||||
|
||||
static int get_cylinder_index(struct dive *dive, struct event *ev)
|
||||
int get_cylinder_index(struct dive *dive, struct event *ev)
|
||||
{
|
||||
int i;
|
||||
int best = 0, score = INT_MAX;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue