diff --git a/core/load-git.c b/core/load-git.c index a5dbf9ccc..0b6d877a6 100644 --- a/core/load-git.c +++ b/core/load-git.c @@ -644,7 +644,7 @@ static char *parse_sample_unit(struct sample *sample, double val, char *unit) /* * If the given cylinder doesn't exist, return NO_SENSOR. */ -static uint8_t sanitize_sensor_id(const struct dive *d, int nr) +static int sanitize_sensor_id(const struct dive *d, int nr) { return d && nr >= 0 && nr < d->cylinders.nr ? nr : NO_SENSOR; } diff --git a/core/parse.c b/core/parse.c index e8161b395..fddcdeff4 100644 --- a/core/parse.c +++ b/core/parse.c @@ -393,7 +393,7 @@ void ws_end(struct parser_state *state) /* * If the given cylinder doesn't exist, return NO_SENSOR. */ -static uint8_t sanitize_sensor_id(const struct dive *d, int nr) +static int sanitize_sensor_id(const struct dive *d, int nr) { return d && nr >= 0 && nr < d->cylinders.nr ? nr : NO_SENSOR; }