summaryrefslogtreecommitdiff
path: root/driver_geostar.c
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2017-07-26 14:09:39 -0700
committerGary E. Miller <gem@rellim.com>2017-07-26 14:09:39 -0700
commitf38b2297342a5c900fb664204d2dca5b03a47ccc (patch)
tree5cfa16e094e48e2772d50aa75d4e081478133cde /driver_geostar.c
parent4690c123d8c2afec42d0e19fda353e54eefb466a (diff)
downloadgpsd-f38b2297342a5c900fb664204d2dca5b03a47ccc.tar.gz
Geostar: fix format string mismatch. %d -> %u
Diffstat (limited to 'driver_geostar.c')
-rw-r--r--driver_geostar.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/driver_geostar.c b/driver_geostar.c
index a8719a86..5866ddce 100644
--- a/driver_geostar.c
+++ b/driver_geostar.c
@@ -435,8 +435,10 @@ static gps_mask_t geostar_analyze(struct gps_device_t *session)
ul1 = getleu32(buf, OFFSET(2));
ul2 = getleu32(buf, OFFSET(3));
ul3 = getleu32(buf, OFFSET(4));
- (void)snprintf(session->subtype, sizeof(session->subtype), "%d.%d %d.%d.%d %x %c-%d\n",
- ul4>>16, ul4&0xFFFF, ul1>>9, (ul1>>5)&0xF, ul1&0x1F, ul2, ul3>>24, ul3&0x00FFFFFF);
+ (void)snprintf(session->subtype, sizeof(session->subtype),
+ "%u.%u %u.%u.%u %x %c-%u\n",
+ ul4>>16, ul4&0xFFFF, ul1>>9, (ul1>>5)&0xF, ul1&0x1F, ul2,
+ ul3>>24, ul3&0x00FFFFFF);
gpsd_log(&session->context->errout, LOG_INF,
"Response to Request FW version command: %s\n",
session->subtype);