e7eb63db94
- adding zero.patch to make ZEROIZE error go away on fedora 7
27 lines
833 B
Diff
27 lines
833 B
Diff
--- libgpsd_core.c.orig 2008-03-19 12:11:55.000000000 -0700
|
|
+++ libgpsd_core.c 2008-03-19 12:14:28.000000000 -0700
|
|
@@ -415,6 +415,7 @@
|
|
tm.tm_mon++;
|
|
tm.tm_year %= 100;
|
|
}
|
|
+#define ZEROIZE(x) (isnan(x)!=0 ? 0.0 : x)
|
|
/*@ -usedef @*/
|
|
(void)snprintf(bufp, len,
|
|
"$GPRMC,%02d%02d%02d,%c,%09.4f,%c,%010.4f,%c,%.4f,%.3f,%02d%02d%02d,,",
|
|
@@ -426,14 +427,13 @@
|
|
((session->gpsdata.fix.latitude > 0) ? 'N' : 'S'),
|
|
degtodm(fabs(session->gpsdata.fix.longitude)),
|
|
((session->gpsdata.fix.longitude > 0) ? 'E' : 'W'),
|
|
-#define ZEROIZE(x) (isnan(x)!=0 ? 0.0 : x)
|
|
ZEROIZE(session->gpsdata.fix.speed * MPS_TO_KNOTS),
|
|
ZEROIZE(session->gpsdata.fix.track),
|
|
-#undef ZEROIZE
|
|
tm.tm_mday,
|
|
tm.tm_mon,
|
|
tm.tm_year);
|
|
/*@ +usedef @*/
|
|
+#undef ZEROIZE
|
|
nmea_add_checksum(bufp);
|
|
}
|
|
|