diff options
author | Gary E. Miller <gem@rellim.com> | 2010-04-18 19:50:17 -0700 |
---|---|---|
committer | Gary E. Miller <gem@rellim.com> | 2010-04-18 19:50:17 -0700 |
commit | df655a372c2f0997ac868a7b818ba438d17810ea (patch) | |
tree | 6aef9fe6358319d8fa677b04f5f3fe775c33f33a /driver_tsip.c | |
parent | 262282ffbbfa1756de4fc7f2c6856a4663c907a1 (diff) | |
download | gpsd-df655a372c2f0997ac868a7b818ba438d17810ea.tar.gz |
Smoke out more private copies of gps_week and move into session->context.
Prepare to do the same for Time of Week (tow).
Diffstat (limited to 'driver_tsip.c')
-rw-r--r-- | driver_tsip.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/driver_tsip.c b/driver_tsip.c index d080f651..9d4109d0 100644 --- a/driver_tsip.c +++ b/driver_tsip.c @@ -689,9 +689,10 @@ static gps_mask_t tsip_analyze(struct gps_device_t *session) session->context->leap_seconds = (int)u1; session->context->valid |= LEAP_SECOND_VALID; } + session->context->gps_week = s1; /*@ ignore @*//*@ splint is confused @ */ session->newdata.time = - gpstime_to_unix((int)s1, + gpstime_to_unix(session->context->gps_week, ul1 * 1e-3) - session->context->leap_seconds; /*@ end @*/ session->gpsdata.status = STATUS_NO_FIX; @@ -756,6 +757,7 @@ static gps_mask_t tsip_analyze(struct gps_device_t *session) session->context->leap_seconds = (int)s2; session->context->valid |= LEAP_SECOND_VALID; + session->context->gps_week = s1; session->newdata.time = gpstime_to_unix((int)s1, (double)ul1) - (double)s2; mask |= TIME_IS; |