summaryrefslogtreecommitdiff
path: root/gpsd_json.c
diff options
context:
space:
mode:
authorGary E. Miller <gem@rellim.com>2019-03-15 12:17:02 -0700
committerGary E. Miller <gem@rellim.com>2019-03-15 12:17:02 -0700
commit6821dfd58695973055ad8f6e6e609b076ba2b8d6 (patch)
tree9dfb53edf37684731e3a76b8ef55dd8f7d3b3804 /gpsd_json.c
parentaf1104274a405f97095caa0897b236d6c913f171 (diff)
downloadgpsd-6821dfd58695973055ad8f6e6e609b076ba2b8d6.tar.gz
gpsd_json: epe now in the JSON.
Odd that it was never there before...
Diffstat (limited to 'gpsd_json.c')
-rw-r--r--gpsd_json.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gpsd_json.c b/gpsd_json.c
index 9bc93999..92003c6e 100644
--- a/gpsd_json.c
+++ b/gpsd_json.c
@@ -192,7 +192,9 @@ void json_tpv_dump(const struct gps_device_t *session,
str_appendf(reply, replylen, "\"epx\":%.3f,", gpsdata->fix.epx);
if (isfinite(gpsdata->fix.epy) != 0)
str_appendf(reply, replylen, "\"epy\":%.3f,", gpsdata->fix.epy);
- if ((gpsdata->fix.mode >= MODE_3D) && isfinite(gpsdata->fix.epv) != 0)
+ if (isfinite(gpsdata->fix.epe) != 0)
+ str_appendf(reply, replylen, "\"epe\":%.3f,", gpsdata->fix.epe);
+ if (isfinite(gpsdata->fix.epv) != 0)
str_appendf(reply, replylen, "\"epv\":%.3f,", gpsdata->fix.epv);
if (isfinite(gpsdata->fix.track) != 0)
str_appendf(reply, replylen, "\"track\":%.4f,", gpsdata->fix.track);