evolution-data-server r8714 - in trunk: addressbook addressbook/backends/groupwise addressbook/libedata-book calendar calendar/backends/groupwise calendar/libecal servers/groupwise
- From: abharath svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution-data-server r8714 - in trunk: addressbook addressbook/backends/groupwise addressbook/libedata-book calendar calendar/backends/groupwise calendar/libecal servers/groupwise
- Date: Wed, 30 Apr 2008 09:08:15 +0100 (BST)
Author: abharath
Date: Wed Apr 30 08:08:14 2008
New Revision: 8714
URL: http://svn.gnome.org/viewvc/evolution-data-server?rev=8714&view=rev
Log:
Committing on behalf of Chenthill Palanisamy <pchenthill novell com>
2008-04-29 Chenthill Palanisamy <pchenthill novell com>
** Fixes part of #350143 (bnc)
Severe memory leak in evolution-data-server
Modified:
trunk/addressbook/ChangeLog
trunk/addressbook/backends/groupwise/e-book-backend-groupwise.c
trunk/addressbook/libedata-book/e-book-backend-db-cache.c
trunk/calendar/ChangeLog
trunk/calendar/backends/groupwise/e-cal-backend-groupwise-utils.c
trunk/calendar/backends/groupwise/e-cal-backend-groupwise.c
trunk/calendar/libecal/e-cal-component.c
trunk/servers/groupwise/ChangeLog
trunk/servers/groupwise/e-gw-container.c
trunk/servers/groupwise/e-gw-item.c
Modified: trunk/addressbook/backends/groupwise/e-book-backend-groupwise.c
==============================================================================
--- trunk/addressbook/backends/groupwise/e-book-backend-groupwise.c (original)
+++ trunk/addressbook/backends/groupwise/e-book-backend-groupwise.c Wed Apr 30 08:08:14 2008
@@ -2242,6 +2242,9 @@
view = "name email";
if (search_string) {
+ if (filter)
+ g_object_unref (filter);
+
/* groupwise server supports only name, rebuild the filter */
filter = e_gw_filter_new ();
e_gw_filter_add_filter_component (filter, E_GW_FILTER_OP_BEGINS,
@@ -2298,6 +2301,8 @@
printf("reading contacts from cache took %ld.%03ld seconds\n",
diff/1000,diff%1000);
}
+ if (filter)
+ g_object_unref (filter);
return NULL;
}
else {
@@ -2338,9 +2343,12 @@
if (temp_list)
g_list_free (temp_list);
bonobo_object_unref (book_view);
-
+
+ if (filter)
+ g_object_unref (filter);
+
return NULL;
- }
+ }
/* no summary information found, read from server */
if (enable_debug)
@@ -2363,6 +2371,8 @@
if (status != E_GW_CONNECTION_STATUS_OK) {
e_data_book_view_notify_complete (book_view, GNOME_Evolution_Addressbook_OtherError);
bonobo_object_unref (book_view);
+ if (filter)
+ g_object_unref (filter);
return NULL;
}
Modified: trunk/addressbook/libedata-book/e-book-backend-db-cache.c
==============================================================================
--- trunk/addressbook/libedata-book/e-book-backend-db-cache.c (original)
+++ trunk/addressbook/libedata-book/e-book-backend-db-cache.c Wed Apr 30 08:08:14 2008
@@ -287,6 +287,8 @@
db_error = db->cursor (db, NULL, &dbc, 0);
if (db_error != 0) {
g_warning ("db->cursor failed with %d", db_error);
+ if (sexp)
+ g_object_unref (sexp);
return NULL;
}
Modified: trunk/calendar/backends/groupwise/e-cal-backend-groupwise-utils.c
==============================================================================
--- trunk/calendar/backends/groupwise/e-cal-backend-groupwise-utils.c (original)
+++ trunk/calendar/backends/groupwise/e-cal-backend-groupwise-utils.c Wed Apr 30 08:08:14 2008
@@ -1099,7 +1099,6 @@
e_cal_component_set_dtstamp (comp, &itt_utc);
}
}
- g_free (t);
/* categories */
category_ids = e_gw_item_get_categories (item);
@@ -1120,7 +1119,6 @@
is_allday = e_gw_item_get_is_allday_event (item);
/* start date */
- /* should i duplicate here ? */
t = e_gw_item_get_start_date (item);
if (t) {
itt_utc = icaltime_from_string (t);
@@ -1173,8 +1171,6 @@
}
}
- g_free (t);
-
/* classification */
description = e_gw_item_get_classification (item);
if (description) {
@@ -1310,6 +1306,7 @@
trigger.u.rel_duration = icaldurationtype_from_int (alarm_duration);
e_cal_component_alarm_set_trigger (alarm, trigger);
e_cal_component_add_alarm (comp, alarm);
+ e_cal_component_alarm_free (alarm);
} else
set_default_alarms (comp);
@@ -1706,7 +1703,7 @@
SoupSoapResponse *response;
EGwConnectionStatus status;
SoupSoapParameter *param, *subparam, *param_outstanding;
- const char *session;
+ char *session;
char *outstanding = NULL;
gboolean resend_request = TRUE;
int request_iteration = 0;
@@ -1734,6 +1731,7 @@
response = e_gw_connection_send_message (cnc, msg);
if (!response) {
g_object_unref (msg);
+ g_free (session);
return E_GW_CONNECTION_STATUS_NO_RESPONSE;
}
@@ -1741,6 +1739,7 @@
if (status != E_GW_CONNECTION_STATUS_OK) {
g_object_unref (msg);
g_object_unref (response);
+ g_free (session);
return status;
}
@@ -1748,6 +1747,7 @@
if (!param) {
g_object_unref (response);
g_object_unref (msg);
+ g_free (session);
return E_GW_CONNECTION_STATUS_INVALID_RESPONSE;
}
@@ -1888,7 +1888,10 @@
} /* end of while loop */
/* closeFreeBusySession*/
- return close_freebusy_session (cnc, session);
+ status = close_freebusy_session (cnc, session);
+ g_free (session);
+
+ return status;
}
#define SET_DELTA(fieldname) G_STMT_START{ \
Modified: trunk/calendar/backends/groupwise/e-cal-backend-groupwise.c
==============================================================================
--- trunk/calendar/backends/groupwise/e-cal-backend-groupwise.c (original)
+++ trunk/calendar/backends/groupwise/e-cal-backend-groupwise.c Wed Apr 30 08:08:14 2008
@@ -1365,6 +1365,9 @@
mangled_uri,
NULL);
g_free (mangled_uri);
+ if (priv->local_attachments_store)
+ g_free (priv->local_attachments_store);
+
priv->local_attachments_store =
g_filename_to_uri (filename, NULL, NULL);
g_free (filename);
Modified: trunk/calendar/libecal/e-cal-component.c
==============================================================================
--- trunk/calendar/libecal/e-cal-component.c (original)
+++ trunk/calendar/libecal/e-cal-component.c Wed Apr 30 08:08:14 2008
@@ -1546,6 +1546,7 @@
icalcomponent_remove_property (icalcomp, attachment->prop);
icalproperty_free (attachment->prop);
+ icalattach_unref (attachment->attach);
g_free (attachment);
}
Modified: trunk/servers/groupwise/e-gw-container.c
==============================================================================
--- trunk/servers/groupwise/e-gw-container.c (original)
+++ trunk/servers/groupwise/e-gw-container.c Wed Apr 30 08:08:14 2008
@@ -60,7 +60,7 @@
{
if(user){
g_free(user->email);
- user->email = NULL;
+ g_free (user);
}
g_free (user);
return ;
Modified: trunk/servers/groupwise/e-gw-item.c
==============================================================================
--- trunk/servers/groupwise/e-gw-item.c (original)
+++ trunk/servers/groupwise/e-gw-item.c Wed Apr 30 08:08:14 2008
@@ -453,6 +453,21 @@
priv->end_date = NULL;
}
+ if (priv->delivered_date) {
+ g_free (priv->delivered_date);
+ priv->delivered_date = NULL;
+ }
+
+ if (priv->start_date) {
+ g_free (priv->start_date);
+ priv->start_date = NULL;
+ }
+
+ if (priv->creation_date) {
+ g_free (priv->creation_date);
+ priv->creation_date = NULL;
+ }
+
free_changes (priv->additions);
free_changes (priv->deletions);
free_changes (priv->updates);
@@ -525,7 +540,7 @@
priv->attach_list = NULL ;
priv->simple_fields = g_hash_table_new_full (g_str_hash, g_str_equal, NULL, g_free);
priv->full_name = g_new0(FullName, 1);
- priv->addresses = g_hash_table_new_full (g_str_hash, g_str_equal, NULL, free_postal_address);
+ priv->addresses = g_hash_table_new_full (g_str_hash, g_str_equal, g_free, free_postal_address);
priv->additions = g_hash_table_new(g_str_hash, g_str_equal);
priv->updates = g_hash_table_new (g_str_hash, g_str_equal);
priv->deletions = g_hash_table_new (g_str_hash, g_str_equal);
@@ -1392,7 +1407,7 @@
if (subparam) {
address = g_new0 (PostalAddress, 1);
set_postal_address_from_soap_parameter (address, subparam);
- g_hash_table_insert (item->priv->addresses, "Office", address);
+ g_hash_table_insert (item->priv->addresses, g_strdup ("Office"), address);
}
@@ -1963,8 +1978,11 @@
attach->contentType = soup_soap_parameter_get_string_value (temp) ;
temp = soup_soap_parameter_get_first_child_by_name (attachment_param, "size") ;
- if (temp)
- attach->size = atoi (soup_soap_parameter_get_string_value (temp)) ;
+ if (temp) {
+ value = soup_soap_parameter_get_string_value (temp);
+ attach->size = atoi (value);
+ g_free (value);
+ }
temp = soup_soap_parameter_get_first_child_by_name (attachment_param, "date") ;
if (temp)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]