views: Instrument and fix reference leaks

This commit is contained in:
Georges Basile Stavracas Neto
2018-01-28 12:08:04 -02:00
parent 58b3340736
commit 194407ecfb
6 changed files with 48 additions and 17 deletions
+4 -1
View File
@@ -723,6 +723,9 @@ add_event_to_grid (GcalWeekHeader *self,
gint position;
gint i;
/* Take a reference to the event */
g_object_ref (event);
/* Add at least at the first weekday */
position = add_event_to_weekday (self, event, start);
@@ -1909,7 +1912,7 @@ void
gcal_week_header_remove_event (GcalWeekHeader *self,
const gchar *uuid)
{
GcalEvent *removed_event;
g_autoptr (GcalEvent) removed_event = NULL;
GList *children, *l;
gint weekday;