[libgweather/gnome-3-26] lib: Fix memory and D-Bus match rule leaks
- From: Bastien Nocera <hadess src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libgweather/gnome-3-26] lib: Fix memory and D-Bus match rule leaks
- Date: Thu, 15 Mar 2018 14:10:07 +0000 (UTC)
commit 449a216514655fe2b3f0eead911137e1732d7c08
Author: Bastien Nocera <hadess hadess net>
Date: Thu Mar 15 14:42:15 2018 +0100
lib: Fix memory and D-Bus match rule leaks
From #3:
> The GWeatherInfo settings object is never freed leading not only
> to a memory leak, but also to a dbus match rule leak, which on
> the system bus can quickly result in reaching the maximum amount
> of allowed match rules. See gnome-shell#96.
libgweather/gweather-weather.c | 1 +
1 file changed, 1 insertion(+)
---
diff --git a/libgweather/gweather-weather.c b/libgweather/gweather-weather.c
index be08c8d..0103d75 100644
--- a/libgweather/gweather-weather.c
+++ b/libgweather/gweather-weather.c
@@ -745,6 +745,7 @@ gweather_info_finalize (GObject *object)
GWeatherInfoPrivate *priv = info->priv;
_weather_location_free (&priv->location);
+ g_clear_object (&priv->settings);
if (priv->glocation)
gweather_location_unref (priv->glocation);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]