summaryrefslogtreecommitdiff
diff options
authorSven Baars <svenb.linux@gmail.com>2012-02-09 06:13:01 -0500
committerTarmac <>2012-02-09 06:13:01 -0500
commit36ed43db6eb2a83dd41855f2e53fdcaf15936548 (patch)
tree3d97f38be4b38bfbc391de2ecde8cfde6733bfd3
parenta651d98fabcbc73254c16dc362b351d9c1f933a0 (diff)
parent22643936aa4e7e13f5d4ea6e600ae1f5d9278765 (diff)
Always free the created GVariantBuilder before return of DBusIndicators::Impl::SyncGeometries
This should fix the biggest leak reported in the original valgrind log of https://bugs.launchpad.net/unity/+bug/886467. Fixes: https://bugs.launchpad.net/bugs/886467. Approved by Mikkel Kamstrup Erlandsen. (bzr r1940)
-rw-r--r--UnityCore/DBusIndicators.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/UnityCore/DBusIndicators.cpp b/UnityCore/DBusIndicators.cpp
index 4c1830604..484120f91 100644
--- a/UnityCore/DBusIndicators.cpp
+++ b/UnityCore/DBusIndicators.cpp
@@ -392,7 +392,10 @@ void DBusIndicators::Impl::SyncGeometries(std::string const& name,
}
if (!found_changed_locations)
+ {
+ g_variant_builder_clear(&b);
return;
+ }
g_variant_builder_close(&b);
g_dbus_proxy_call(proxy_, "SyncGeometries",