mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Correct: Handle more tanks than gasmixes
When Suunto Vytecs are used in gauge mode they don't record gasmixes. If a tank pressure sensor is present they nevertheless record the pressures. This patch handles this situation by assuming the tanks contain air (and warning the user about this). [Dirk Hohndel: I had mistakenly pushed out an earlier version of this commit, so this fixes things up to the final version] Reported-by: antonnorth@gmail.com Signed-off-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
8a8315d6fe
commit
67de8f3a49
1 changed files with 2 additions and 2 deletions
|
@ -96,10 +96,10 @@ static int parse_gasmixes(device_data_t *devdata, struct dive *dive, dc_parser_t
|
|||
if (rc == DC_STATUS_SUCCESS) {
|
||||
if (ntanks && ntanks < ngases) {
|
||||
shown_warning = true;
|
||||
report_error("Warning: different number of gases (%d) and tanks (%d)", ngases, ntanks);
|
||||
report_error("Warning: different number of gases (%d) and cylinders (%d)", ngases, ntanks);
|
||||
} else if (ntanks > ngases) {
|
||||
shown_warning = true;
|
||||
report_error("Warning: smaller number of gases (%d) than tanks (%d). Assuming air.", ngases, ntanks);
|
||||
report_error("Warning: smaller number of gases (%d) than cylinders (%d). Assuming air.", ngases, ntanks);
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Add table
Reference in a new issue