Skip to content

Commit

Permalink
fix:vehicle:gpsd:Add Support for Gpsd 3.21
Browse files Browse the repository at this point in the history
  • Loading branch information
jkoan committed Aug 17, 2020
1 parent 27d4844 commit 5c3a9e1
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion navit/vehicle/gpsd/vehicle_gpsd.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
* Boston, MA 02110-1301, USA.
*/

#include <config.h>
#include <gps.h>
#include <string.h>
#include <glib.h>
Expand Down Expand Up @@ -166,7 +165,12 @@ vehicle_gpsd_callback(struct gps_data_t *data, const char *buf, size_t len,
data->set &= ~SATELLITE_SET;
}
if (data->set & STATUS_SET) {
#if GPSD_API_MAJOR_VERSION >= 10
priv->status = data->fix.status;
#else
priv->status = data->status;
#endif // GPSD_API_MAJOR_VERSION >= 9

data->set &= ~STATUS_SET;
}
if (data->set & MODE_SET) {
Expand Down

0 comments on commit 5c3a9e1

Please sign in to comment.