+2004-12-09 Harish Krishnamwamy <kharish@novell.com>
+ Fixes for various leaks causing memory build-ups in eds.
+
+ * libecal/e-cal-listener.c (impl_notifyFreeBusy):
+ l->data should be unref'd - not free'd.
+ * libedata-cal/e-cal-backend.c (get_queries):
+ Do not ref the queries while returning them. This is unnecessary.
+ * libedata-cal/e-cal-backend-sexp.c (e_cal_backend_sexp_match_comp) :
+ unref the comp and backend while returning.
+
+
2004-12-06 Harish Krishnaswamy <kharish@novell.com>
* backends/groupwise/e-cal-backend-groupwise-utils.c
(e_gw_connection_send_appointment) : Add correct view arguments
g_signal_emit (G_OBJECT (listener), signals[GET_FREE_BUSY], 0, convert_status (status), freebusy);
for (l = freebusy; l; l = l->next)
- g_free (l->data);
+ g_object_unref (G_OBJECT (l->data));
g_list_free (freebusy);
}
comp = e_cal_component_new ();
e_cal_component_set_icalcomponent (comp, icalcomponent_new_clone (subcomp));
*objects = g_list_append (*objects, comp);
-
subcomp = icalcomponent_get_next_component (icalcomp, kind_to_find);
}
}
generate_instances (ECal *ecal, time_t start, time_t end, const char *uid,
ECalRecurInstanceFn cb, gpointer cb_data)
{
- GList *objects;
+ GList *objects = NULL;
GList *instances, *detached_instances = NULL;
GList *l;
char *query;
sexp->priv->search_context->backend = g_object_ref (backend);
/* if it's not a valid vcard why is it in our db? :) */
- if (!sexp->priv->search_context->comp)
+ if (!sexp->priv->search_context->comp) {
+ g_object_unref (sexp->priv->search_context->comp);
+ g_object_unref (sexp->priv->search_context->backend);
return FALSE;
-
+ }
r = e_sexp_eval(sexp->priv->search_sexp);
retval = (r && r->type == ESEXP_RES_BOOL && r->value.bool);
g_return_val_if_fail (backend != NULL, NULL);
g_return_val_if_fail (E_IS_CAL_BACKEND (backend), NULL);
- return g_object_ref (backend->priv->queries);
+ return backend->priv->queries;
}