Use the correct field for the setpoint sample
This only happened to work correctly because both the setpoint and ppO2 field have the same data type and are located at the same offset in the union.
This commit is contained in:
parent
9eef8c50c0
commit
4e83b1642c
@ -829,11 +829,11 @@ static void sample_setpoint_type(const struct type_desc *desc, struct sample_dat
|
||||
}
|
||||
|
||||
if (!strcasecmp(type, "Low"))
|
||||
sample.ppo2 = info->eon->cache.lowsetpoint;
|
||||
sample.setpoint = info->eon->cache.lowsetpoint;
|
||||
else if (!strcasecmp(type, "High"))
|
||||
sample.ppo2 = info->eon->cache.highsetpoint;
|
||||
sample.setpoint = info->eon->cache.highsetpoint;
|
||||
else if (!strcasecmp(type, "Custom"))
|
||||
sample.ppo2 = info->eon->cache.customsetpoint;
|
||||
sample.setpoint = info->eon->cache.customsetpoint;
|
||||
else {
|
||||
DEBUG(info->eon->base.context, "sample_setpoint_type(%u) unknown type '%s'", value, type);
|
||||
free(type);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user