summaryrefslogtreecommitdiff
path: root/monitor_nmea.c
diff options
context:
space:
mode:
Diffstat (limited to 'monitor_nmea.c')
-rw-r--r--monitor_nmea.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/monitor_nmea.c b/monitor_nmea.c
index 6a632006..fb957772 100644
--- a/monitor_nmea.c
+++ b/monitor_nmea.c
@@ -329,13 +329,13 @@ static void nmea_update(void)
if (pps_thread_lastpps(&session, &drift) > 0) {
/* NOTE: can not use double here due to precision requirements */
struct timespec timedelta;
- char buf[22];
TS_SUB( &timedelta, &drift.clock, &drift.real);
if ( 86400 < (long)labs(timedelta.tv_sec) ) {
/* more than one day off, overflow */
/* need a bigger field to show it */
(void)mvwprintw(gpgsawin, 4, 13, "> 1 day");
} else {
+ char buf[22];
(void)timespec_str( &timedelta, buf, sizeof(buf) );
(void)mvwprintw(gpgsawin, 4, 13, "%s", buf);
}