summaryrefslogtreecommitdiffstats
path: root/subsurface-core
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2016-03-09 18:25:30 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-03-09 21:47:07 -0800
commit1dab8800e5f0b768b72892930314c8ad63b2b568 (patch)
tree4566047b42bd9d3d25407e08d943cef4ebccda42 /subsurface-core
parentba34b168be72fac599fadb023f59f5429dda57f1 (diff)
downloadsubsurface-1dab8800e5f0b768b72892930314c8ad63b2b568.tar.gz
Clean up signedness confusion in libdivecomputer.c
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'subsurface-core')
-rw-r--r--subsurface-core/libdivecomputer.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/subsurface-core/libdivecomputer.c b/subsurface-core/libdivecomputer.c
index 5587590b8..549b894ce 100644
--- a/subsurface-core/libdivecomputer.c
+++ b/subsurface-core/libdivecomputer.c
@@ -71,13 +71,14 @@ static dc_status_t create_parser(device_data_t *devdata, dc_parser_t **parser)
return dc_parser_new(parser, devdata->device);
}
-static int parse_gasmixes(device_data_t *devdata, struct dive *dive, dc_parser_t *parser, int ngases)
+static int parse_gasmixes(device_data_t *devdata, struct dive *dive, dc_parser_t *parser, unsigned int ngases)
{
static bool shown_warning = false;
- int i, rc;
+ unsigned int i;
+ int rc;
#if DC_VERSION_CHECK(0, 5, 0) && defined(DC_GASMIX_UNKNOWN)
- int ntanks = 0;
+ unsigned int ntanks = 0;
rc = dc_parser_get_field(parser, DC_FIELD_TANK_COUNT, 0, &ntanks);
if (rc == DC_STATUS_SUCCESS) {
if (ntanks && ntanks != ngases) {