diff options
author | Eric S. Raymond <esr@thyrsus.com> | 2011-06-14 18:52:34 -0400 |
---|---|---|
committer | Eric S. Raymond <esr@thyrsus.com> | 2011-06-14 18:52:34 -0400 |
commit | e5cf5cd806ee0277ec4174acc9dfdf7cb0c85f64 (patch) | |
tree | 45a78c70c07dcc003de6e9a4f998bba9620d54f8 /gpsd.c | |
parent | 6d3452b088042bcb6deb9521efa53dd0f9a029cd (diff) | |
download | gpsd-e5cf5cd806ee0277ec4174acc9dfdf7cb0c85f64.tar.gz |
First xut at JSON passthrough code.
Not turned in by default yet; it interferes with RTCM2 decoding.
Diffstat (limited to 'gpsd.c')
-rw-r--r-- | gpsd.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -1566,6 +1566,16 @@ static void consume_packets(struct gps_device_t *device) if (sub == NULL || sub->active == 0 || !subscribed(sub, device)) continue; +#ifdef PASSTHROUGH_ENABLE + /* this is for passing through JSON packets */ + if ((changed & PASSTHROUGH_IS) != 0) { + (void)throttled_write(sub, + (char *)device->packet.outbuffer, + device->packet.outbuflen); + continue; + } +#endif /* PASSTHROUGH_ENABLE */ + /* report raw packets to users subscribed to those */ raw_report(sub, device); |