]> git.street.me.uk Git - andy/viking.git/commitdiff
[QA] Fixup if statement intention.
authorRob Norris <rw_norris@hotmail.com>
Tue, 10 Sep 2013 22:03:08 +0000 (23:03 +0100)
committerRob Norris <rw_norris@hotmail.com>
Tue, 10 Sep 2013 22:04:08 +0000 (23:04 +0100)
Highlighted as issue when compiling with clang 3.2

src/vikgpslayer.c

index 4e1f746739199a3339c40bdaf48067b826dc883a..14aa083d115e63867fda3544321a4c291ff93382 100644 (file)
@@ -562,8 +562,8 @@ static gboolean gps_layer_set_param ( VikGpsLayer *vgl, guint16 id, VikLayerPara
       break;
     case PARAM_GPSD_PORT:
       if (data.s) {
-        if (vgl->gpsd_port);
-        g_free(vgl->gpsd_port);
+        if (vgl->gpsd_port)
+          g_free(vgl->gpsd_port);
         vgl->gpsd_port = g_strdup(data.s);
       }
       break;