Michael Werle fae68b7a68 fix: merge_pressure does not calculate starting pressures correctly
The existing logic correctly calculates the minimum (ie, ending) pressure, but not the maximum
(ie starting) pressure.

For example, 2 tanks A and B with manual pressures (same tank on subsequent dives, which were
then merged):
A: 205 - 84
B: 83 - 55

When merging the starting pressures, the call is : merge_pressure(205, 0, 83, 0, false)

The final comparison is:
  if(false && 205 < 83) return 205;
  else return 83;

-> So 83 is returned even though 205 should have been.

Signed-off-by: Michael Werle <micha@michaelwerle.com>
2023-08-09 14:35:32 +02:00
..
2022-08-30 07:20:33 -07:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-02-17 06:46:46 -08:00
2017-04-29 13:32:55 -07:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2021-07-23 11:22:43 -07:00
2023-04-14 21:20:23 +02:00
2020-09-29 16:13:03 -07:00
2022-11-08 10:43:47 -08:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-06-12 08:04:30 -07:00
2021-07-23 11:22:43 -07:00
2021-07-23 11:22:43 -07:00
2018-10-21 19:55:09 +03:00
2023-04-14 21:20:23 +02:00
2022-03-13 15:07:33 -07:00
2022-03-12 08:28:32 -08:00
2021-07-23 11:16:00 -07:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2023-04-14 21:20:23 +02:00
2019-12-13 07:04:00 -05:00
2017-04-29 13:32:55 -07:00
2020-03-10 17:42:54 -07:00
2020-03-10 17:42:54 -07:00
2022-06-04 14:19:05 -07:00