diff options
author | Gary E. Miller <gem@rellim.com> | 2019-02-07 13:26:12 -0800 |
---|---|---|
committer | Gary E. Miller <gem@rellim.com> | 2019-02-07 13:26:12 -0800 |
commit | 9bbfa97c7094160e28086e16019370376874482b (patch) | |
tree | 8c15e36602df03aa958411fafe762efdeec520e7 /monitor_sirf.c | |
parent | b262e0e68816c92f6fe464a1eaf54365acd40241 (diff) | |
download | gpsd-9bbfa97c7094160e28086e16019370376874482b.tar.gz |
gpsmon: Don't try to convert NaN to isotime.
A drop in the buckect of the mess that is gpsmon.
Diffstat (limited to 'monitor_sirf.c')
-rw-r--r-- | monitor_sirf.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/monitor_sirf.c b/monitor_sirf.c index 372b528e..9f9b75b5 100644 --- a/monitor_sirf.c +++ b/monitor_sirf.c @@ -286,9 +286,11 @@ static void sirf_update(void) 17) / 8); /* line 3 */ (void)wmove(mid2win, 3, 7); - (void)wprintw(mid2win, "%-24s", - unix_to_iso8601(session.gpsdata.fix.time, tbuf, sizeof(tbuf)) - ); + if (isfinite(session.gpsdata.fix.time)) { + (void)wprintw(mid2win, "%-24s", + unix_to_iso8601(session.gpsdata.fix.time, tbuf, + sizeof(tbuf))); + } (void)wmove(mid2win, 3, 38); (void)wattrset(mid2win, A_UNDERLINE); if (ppstime_enabled) |