Diff between 6ea0d095677075db24e08130a5290b818da38e7d and 685d07096683a1166a69302bcf967fa0518fb121

Changed Files

File Additions Deletions Status
src/gatt-database.c +3 -8 modified

Full Patch

diff --git a/src/gatt-database.c b/src/gatt-database.c
index d4dd661..e887bd2 100644
--- a/src/gatt-database.c
+++ b/src/gatt-database.c
@@ -351,20 +351,15 @@ static void service_free(void *data)
 		g_dbus_client_set_proxy_handlers(service->client, NULL, NULL,
 								NULL, NULL);
 		g_dbus_client_set_ready_watch(service->client, NULL, NULL);
+		g_dbus_proxy_unref(service->proxy);
 		g_dbus_client_unref(service->client);
 	}
 
-	if (service->proxy)
-		g_dbus_proxy_unref(service->proxy);
-
 	if (service->reg)
 		dbus_message_unref(service->reg);
 
-	if (service->owner)
-		g_free(service->owner);
-
-	if (service->path)
-		g_free(service->path);
+	g_free(service->owner);
+	g_free(service->path);
 
 	free(service);
 }