[gnome-panel/wip/muktupavels/issue-42: 5/5] clock: fix memory leaks
- From: Alberts Muktupāvels <muktupavels src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-panel/wip/muktupavels/issue-42: 5/5] clock: fix memory leaks
- Date: Sun, 16 Oct 2022 22:14:03 +0000 (UTC)
commit 2c4eb82d5f7e1a2ca40d26cea17532ed6bcac263
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date: Sun Oct 16 22:20:48 2022 +0300
clock: fix memory leaks
https://gitlab.gnome.org/GNOME/gnome-panel/-/issues/42
modules/clock/clock-applet.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/modules/clock/clock-applet.c b/modules/clock/clock-applet.c
index e94286f64..060774bd5 100644
--- a/modules/clock/clock-applet.c
+++ b/modules/clock/clock-applet.c
@@ -419,10 +419,10 @@ create_cities_store (ClockApplet *cd)
}
/* City name, Timezone name, Coordinates in lat/long */
- cd->cities_store = g_object_ref (gtk_list_store_new (COL_CITY_LAST,
- G_TYPE_STRING, /* COL_CITY_NAME */
- G_TYPE_STRING, /* COL_CITY_TZ */
- CLOCK_LOCATION_TYPE)); /* COL_CITY_LOC */
+ cd->cities_store = gtk_list_store_new (COL_CITY_LAST,
+ G_TYPE_STRING, /* COL_CITY_NAME */
+ G_TYPE_STRING, /* COL_CITY_TZ */
+ CLOCK_LOCATION_TYPE); /* COL_CITY_LOC */
list = g_list_copy (cities);
list = g_list_sort (list, sort_locations_by_name);
@@ -1733,6 +1733,7 @@ clock_applet_dispose (GObject *object)
g_clear_object (&applet->wall_clock);
g_clear_pointer (&applet->calendar_popup, gtk_widget_destroy);
+ g_clear_pointer (&applet->prefs_window, gtk_widget_destroy);
g_clear_object (&applet->datetime_appinfo);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]