diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2013-10-25 10:41:46 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2013-10-25 10:41:46 -0400 |
commit | a9f44d1cb9db5a27832782bbe2685e66433c6d3a (patch) | |
tree | a8778b1511959255a7ba7d1db9ce1aa112fa87a5 /driver_nmea0183.c | |
parent | 02c98b88b58cb3d1bcff86e0807587a60d7fee69 (diff) | |
download | gpsd-a9f44d1cb9db5a27832782bbe2685e66433c6d3a.tar.gz |
Remove a redundant test, and explain the redundancy.
Diffstat (limited to 'driver_nmea0183.c')
-rw-r--r-- | driver_nmea0183.c | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/driver_nmea0183.c b/driver_nmea0183.c index 7d480781..fd17df4a 100644 --- a/driver_nmea0183.c +++ b/driver_nmea0183.c @@ -1300,14 +1300,12 @@ gps_mask_t nmea_parse(char *sentence, struct gps_device_t * session) session->driver.nmea.date.tm_min, session->driver.nmea.date.tm_sec + session->driver.nmea.subseconds); /* - * Conservative heuristic for whether we should try using the - * device for precision time service. Wait for it to stabilize - * after initialization. (We know this is required on some - * Garmins in binary mode; safest to do it in case we're - * talking to a Garmin in text mode.) + * If we have time and PPS is available, assume we have good time. + * Because this is a generic driver we don't really have enough + * information for a sharper test, so we'll leave it up to the + * PPS code to do its own sanity filtering. */ - if (session->fixcnt > 3) - retval |= PPSTIME_IS; + retval |= PPSTIME_IS; } /* |