diff options
author | Chris Talbot <chris@talbothome.com> | 2023-05-14 12:24:01 -0400 |
---|---|---|
committer | Teemu Ikonen <tpikonen@mailbox.org> | 2023-07-08 12:04:05 +0000 |
commit | 9535c3beeb7f1c9da2180eaba13b1a45a0edb72e (patch) | |
tree | 04575f55f4a4862d213cd072afe41bf5400db321 | |
parent | df7018f39f30a1cbc60f712f2d1c33d26695f04d (diff) |
gclue-location: Don't add any GPS locations if the GGA sentence doesn't show a fix
-rw-r--r-- | src/gclue-location.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/gclue-location.c b/src/gclue-location.c index 823231a..6fae623 100644 --- a/src/gclue-location.c +++ b/src/gclue-location.c @@ -610,6 +610,11 @@ gclue_location_create_from_gga (const char *gga, GError **error) return NULL; } + if (g_ascii_strtoll (parts[6], NULL, 10) == 0) { + /* No fix, ignore. */ + return NULL; + } + /* For syntax of GGA sentences: * http://www.gpsinformation.org/dale/nmea.htm#GGA */ |