summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--gpsd_dbus.c2
-rw-r--r--gpxlogger.c8
2 files changed, 8 insertions, 2 deletions
diff --git a/gpsd_dbus.c b/gpsd_dbus.c
index a8772c1e..dfd271b6 100644
--- a/gpsd_dbus.c
+++ b/gpsd_dbus.c
@@ -40,7 +40,7 @@ void send_dbus_fix(struct gps_device_t* channel) {
gpsdata = &(channel->gpsdata);
gpsfix = &(gpsdata->fix);
- gpsd_devname = gpsdata->gps_device;
+ gpsd_devname = gpsdata->dev.path;
/* Send the named signel. */
message = dbus_message_new_signal("/org/gpsd", "org.gpsd", "fix");
diff --git a/gpxlogger.c b/gpxlogger.c
index 8f0a2033..a9c32ead 100644
--- a/gpxlogger.c
+++ b/gpxlogger.c
@@ -172,6 +172,12 @@ static struct gps_fix_t gpsfix;
#include <glib/gprintf.h>
+/*
+ * FIXME: use here is a minor bug, should report epx and epy separately.
+ * How to mix together epx and epy to get a horizontal circular error.
+ */
+#define EMIX(x, y) (((x) > (y)) ? (x) : (y))
+
DBusConnection* connection;
static char gpsd_devname[BUFSIZ];
@@ -180,7 +186,7 @@ static DBusHandlerResult handle_gps_fix (DBusMessage* message)
{
DBusError error;
/* this packet format was designed before we split eph */
- double eph = EMIX(gpsfix->epx, gpsfix->epy);
+ double eph = EMIX(gpsfix.epx, gpsfix.epy);
dbus_error_init (&error);