]> err.no Git - mapper/commitdiff
Don't clear gps address, zero gps data.
authorKaj-Michael Lang <milang@tal.org>
Tue, 18 Mar 2008 17:11:32 +0000 (19:11 +0200)
committerKaj-Michael Lang <milang@tal.org>
Tue, 18 Mar 2008 17:11:32 +0000 (19:11 +0200)
src/gps.c

index 8bc3defbd549c55def621197f0a4859cf55c2971..718dd5574d599c28550394628459261c98534b60 100644 (file)
--- a/src/gps.c
+++ b/src/gps.c
@@ -115,21 +115,14 @@ gps_clear(Gps *gps)
 {
 g_assert(gps);
 gps->io.fd=-1;
-gps->io.address=NULL;
 gps->io.conn=RCVR_OFF;
-gps->io.nmea=NULL;
 gps->io.nmea_cnt=0;
+memset(&gps->data, 0, sizeof(gps->data));
 gps->data.fix=FIX_NOFIX;
 gps->data.lat=60.20;
 gps->data.lon=22.20;
 gps->data.satinview=0;
 gps->data.satinuse=0;
-gps->connection_error=NULL;
-gps->connection_retry=NULL;
-gps->connection_progress=NULL;
-gps->update_location=NULL;
-gps->update_info=NULL;
-gps->update_satellite=NULL;
 gps_data_integerize(&gps->data);
 }