mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-01 00:23:23 +00:00
planner: Correct pO2 comparison
Don't compare pO2 with a bool, compare it with the result of the ?: expression instead. Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
44a554d53a
commit
3dbc5bfeaa
1 changed files with 1 additions and 1 deletions
|
@ -674,7 +674,7 @@ static void add_plan_to_notes(struct diveplan *diveplan, struct dive *dive, bool
|
|||
if (dp->time != 0) {
|
||||
int pO2 = depth_to_atm(dp->depth, dive) * get_o2(&dp->gasmix);
|
||||
|
||||
if (pO2 > dp->entered ? prefs.bottompo2 : prefs.decopo2) {
|
||||
if (pO2 > (dp->entered ? prefs.bottompo2 : prefs.decopo2)) {
|
||||
const char *depth_unit;
|
||||
int decimals;
|
||||
double depth_value = get_depth_units(dp->depth, &decimals, &depth_unit);
|
||||
|
|
Loading…
Add table
Reference in a new issue