diff options
author | Gary E. Miller <gem@rellim.com> | 2018-09-25 17:24:27 -0700 |
---|---|---|
committer | Gary E. Miller <gem@rellim.com> | 2018-09-25 17:24:27 -0700 |
commit | 1a5c424ccbfd1c10130a34ca718108ed51a14735 (patch) | |
tree | 710f7ad2b1b434d4636ffa4c2a20bdbb194a426a /driver_ubx.c | |
parent | 2afae53633806d13c9fc6847388bfd56b5900b11 (diff) | |
download | gpsd-1a5c424ccbfd1c10130a34ca718108ed51a14735.tar.gz |
driver_ubx: cppcheck tweak to variable scope.
Diffstat (limited to 'driver_ubx.c')
-rw-r--r-- | driver_ubx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/driver_ubx.c b/driver_ubx.c index e140bf15..be88cc87 100644 --- a/driver_ubx.c +++ b/driver_ubx.c @@ -169,7 +169,6 @@ ubx_msg_nav_pvt(struct gps_device_t *session, unsigned char *buf, uint8_t flags; uint8_t navmode; struct tm unpacked_date; - double subseconds; double hacc, vacc, sacc; int *status = &session->gpsdata.status; int *mode = &session->newdata.mode; @@ -246,6 +245,7 @@ ubx_msg_nav_pvt(struct gps_device_t *session, unsigned char *buf, } if ((valid & UBX_NAV_PVT_VALID_DATE_TIME) == UBX_NAV_PVT_VALID_DATE_TIME) { + double subseconds; unpacked_date.tm_year = (uint16_t)getleu16(buf, 4) - 1900; unpacked_date.tm_mon = (uint8_t)getub(buf, 6) - 1; unpacked_date.tm_mday = (uint8_t)getub(buf, 7); |