mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Define O2 permille for air in one spot
Having the O2 permille defined once is more readable. Signed-off-by: Henrik Brautaset Aronsen <subsurface@henrik.synth.no>
This commit is contained in:
parent
2175226580
commit
16b6df559f
5 changed files with 8 additions and 6 deletions
|
@ -109,7 +109,7 @@ static int parse_gasmixes(struct dive *dive, parser_t *parser, int ngases)
|
|||
he = gasmix.helium * 1000 + 0.5;
|
||||
|
||||
/* Ignore bogus data - libdivecomputer does some crazy stuff */
|
||||
if (o2 < 210 || o2 >= 1000)
|
||||
if (o2 <= AIR_PERMILLE || o2 >= 1000)
|
||||
o2 = 0;
|
||||
if (he < 0 || he >= 800 || o2+he >= 1000)
|
||||
he = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue