Changeset 3249
- Timestamp:
- 01/14/08 02:06:57
- Files:
-
- trunk/ChangeLog (modified) (1 diff)
- trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-command.c (modified) (6 diffs)
- trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-folder.c (modified) (4 diffs)
- trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-store-summary.c (modified) (4 diffs)
- trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-store-summary.h (modified) (1 diff)
- trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-store.c (modified) (7 diffs)
- trunk/libtinymail-camel/camel-lite/camel/providers/local/camel-maildir-folder.c (modified) (1 diff)
- trunk/libtinymail-camel/tny-camel-msg-header.c (modified) (1 diff)
- trunk/libtinymail-gnome-desktop/tny-gnome-device.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/ChangeLog
r3248 r3249 1 2008-01-14 Philip Van Hoof <pvanhoof@gnome.org> 2 3 * Some aggresive memory checking revealed a few interesting memory 4 leaks. This commit fixes those. The fixes are experimental, although 5 most of them double checked. 6 7 CamelOperation holds one more significant memory leak at its 8 status_hack linked list. That one is not yet fixed. 9 1 10 2008-01-13 Philip Van Hoof <pvanhoof@gnome.org> 2 11 trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-command.c
r3235 r3249 373 373 imap_debug ("Recon in start: %s\n", camel_exception_get_description (&mex)); 374 374 375 camel_exception_clear (&mex); 375 376 return FALSE; 376 377 } … … 414 415 imap_debug ("Recon in cont: %s\n", camel_exception_get_description (&mex)); 415 416 CAMEL_SERVICE_REC_UNLOCK (store, connect_lock); 417 camel_exception_clear (&mex); 416 418 return NULL; 417 419 } else … … 711 713 camel_imap_recon (store, &mex); 712 714 imap_debug ("Recon in untagged: %s\n", camel_exception_get_description (&mex)); 715 camel_exception_clear (&mex); 713 716 } else { 714 717 camel_exception_set (ex, CAMEL_EXCEPTION_SERVICE_UNAVAILABLE, … … 730 733 camel_imap_recon (store, &mex); 731 734 imap_debug ("Recon in untagged idle: %s\n", camel_exception_get_description (&mex)); 735 camel_exception_clear (&mex); 732 736 } else { 733 737 camel_exception_set (ex, CAMEL_EXCEPTION_SERVICE_UNAVAILABLE, … … 874 878 camel_imap_recon (store, &mex); 875 879 imap_debug ("Recon in untagged: %s\n", camel_exception_get_description (&mex)); 880 camel_exception_clear (&mex); 876 881 } else { 877 882 camel_exception_set (ex, CAMEL_EXCEPTION_SERVICE_UNAVAILABLE, … … 893 898 camel_imap_recon (store, &mex); 894 899 imap_debug ("Recon in untagged idle: %s\n", camel_exception_get_description (&mex)); 900 camel_exception_clear (&mex); 895 901 } else { 896 902 camel_exception_set (ex, CAMEL_EXCEPTION_SERVICE_UNAVAILABLE, trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-folder.c
r3245 r3249 3299 3299 store->dontdistridlehack = FALSE; 3300 3300 3301 if (mchanges) { 3302 if (camel_folder_change_info_changed (mchanges)) 3303 camel_object_trigger_event (CAMEL_OBJECT (folder), "folder_changed", mchanges); 3304 camel_folder_change_info_free (mchanges); 3305 mchanges = NULL; 3306 } 3307 3301 3308 camel_service_disconnect (CAMEL_SERVICE (store), FALSE, NULL); 3302 3309 … … 3398 3405 store->dontdistridlehack = FALSE; 3399 3406 3407 if (mchanges) { 3408 if (camel_folder_change_info_changed (mchanges)) 3409 camel_object_trigger_event (CAMEL_OBJECT (folder), "folder_changed", mchanges); 3410 camel_folder_change_info_free (mchanges); 3411 mchanges = NULL; 3412 } 3413 3400 3414 camel_service_disconnect (CAMEL_SERVICE (store), FALSE, NULL); 3401 3415 … … 3423 3437 camel_folder_summary_kill_hash (folder->summary); 3424 3438 store->dontdistridlehack = FALSE; 3439 3440 if (mchanges) { 3441 if (camel_folder_change_info_changed (mchanges)) 3442 camel_object_trigger_event (CAMEL_OBJECT (folder), "folder_changed", mchanges); 3443 camel_folder_change_info_free (mchanges); 3444 mchanges = NULL; 3445 } 3425 3446 3426 3447 camel_service_disconnect (CAMEL_SERVICE (store), FALSE, NULL); … … 5346 5367 err = TRUE; 5347 5368 ex_id = CAMEL_EXCEPTION_SERVICE_UNAVAILABLE; 5348 errmessage = errmessage =g_strdup_printf ("Message with UID %s does not exists", uid);5369 errmessage = g_strdup_printf ("Message with UID %s does not exists", uid); 5349 5370 } else{ 5350 5371 err = TRUE; trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-store-summary.c
r3235 r3249 50 50 51 51 static void namespace_clear(CamelStoreSummary *s); 52 53 static void namespace_free(CamelStoreSummary *s, CamelImapStoreNamespace *ns); 52 54 53 55 static int summary_header_load(CamelStoreSummary *, FILE *); … … 439 441 } 440 442 441 voidcamel_imap_store_summary_namespace_add(CamelImapStoreSummary *s, CamelImapStoreNamespace *ns)443 CamelImapStoreNamespace * camel_imap_store_summary_namespace_add(CamelImapStoreSummary *s, CamelImapStoreNamespace *ns) 442 444 { 443 445 gboolean add = TRUE; 444 446 GList *lst = s->namespaces; 447 CamelImapStoreNamespace *ret = NULL; 445 448 446 449 while (lst) { … … 448 451 if (n->full_name && ns->full_name && !strcmp (n->full_name, ns->full_name)) { 449 452 add = FALSE; 453 ret = n; 450 454 break; 451 455 } … … 453 457 } 454 458 455 if (add) 459 if (add) { 456 460 s->namespaces = g_list_prepend (s->namespaces, ns); 457 458 return; 461 ret = ns; 462 } else 463 namespace_free((CamelStoreSummary*)s, ns); 464 465 return ret; 459 466 } 460 467 trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-store-summary.h
r3177 r3249 78 78 CamelImapStoreNamespace *camel_imap_store_summary_namespace_new(CamelImapStoreSummary *s, const char *full_name, char dir_sep); 79 79 void camel_imap_store_summary_namespace_set(CamelImapStoreSummary *s, CamelImapStoreNamespace *ns); 80 voidcamel_imap_store_summary_namespace_add(CamelImapStoreSummary *s, CamelImapStoreNamespace *ns);80 CamelImapStoreNamespace *camel_imap_store_summary_namespace_add(CamelImapStoreSummary *s, CamelImapStoreNamespace *ns); 81 81 CamelImapStoreNamespace *camel_imap_store_summary_namespace_find_path(CamelImapStoreSummary *s, const char *path); 82 82 CamelImapStoreNamespace *camel_imap_store_summary_namespace_find_full(CamelImapStoreSummary *s, const char *full_name); trunk/libtinymail-camel/camel-lite/camel/providers/imap/camel-imap-store.c
r3235 r3249 1899 1899 if (namespaces && namespaces->personal) { 1900 1900 ns = camel_imap_store_summary_namespace_new(store->summary, namespaces->personal->prefix, namespaces->personal->delim); 1901 camel_imap_store_summary_namespace_add(store->summary,ns);1901 ns = camel_imap_store_summary_namespace_add(store->summary,ns); 1902 1902 camel_imap_store_summary_namespace_set(store->summary, ns); 1903 1903 } … … 1905 1905 if (namespaces && namespaces->other) { 1906 1906 ns = camel_imap_store_summary_namespace_new(store->summary, namespaces->other->prefix, namespaces->other->delim); 1907 camel_imap_store_summary_namespace_add(store->summary,ns);1907 ns = camel_imap_store_summary_namespace_add(store->summary,ns); 1908 1908 } 1909 1909 1910 1910 if (namespaces && namespaces->shared) { 1911 1911 ns = camel_imap_store_summary_namespace_new(store->summary, namespaces->shared->prefix, namespaces->shared->delim); 1912 camel_imap_store_summary_namespace_add(store->summary,ns);1912 ns = camel_imap_store_summary_namespace_add(store->summary,ns); 1913 1913 } 1914 1914 … … 3586 3586 hfi->unread = fi->unread; 3587 3587 hfi->total = fi->total; 3588 camel_folder_info_free(fi); 3588 3589 } 3589 3590 } … … 3651 3652 hfi->total = fi->total; 3652 3653 } 3654 camel_folder_info_free(fi); 3653 3655 } 3654 3656 } … … 3725 3727 fi->flags |= CAMEL_FOLDER_SUBSCRIBED; 3726 3728 g_hash_table_insert(present, fi->full_name, fi); 3727 } 3729 } else 3730 camel_folder_info_free(fi); 3728 3731 } 3729 3732 … … 4193 4196 camel_imap_recon (store, &mex); 4194 4197 imap_debug ("Recon: %s\n", camel_exception_get_description (&mex)); 4198 camel_exception_clear (&mex); 4195 4199 } else { 4196 4200 camel_exception_setv (ex, CAMEL_EXCEPTION_SERVICE_UNAVAILABLE, … … 4268 4272 camel_imap_recon (store, &mex); 4269 4273 imap_debug ("Recon in nl: %s\n", camel_exception_get_description (&mex)); 4274 camel_exception_clear (&mex); 4270 4275 } else { 4271 4276 camel_exception_setv (ex, CAMEL_EXCEPTION_SERVICE_UNAVAILABLE, trunk/libtinymail-camel/camel-lite/camel/providers/local/camel-maildir-folder.c
r3235 r3249 206 206 *appended_uid = g_strdup(camel_message_info_uid(mi)); 207 207 208 if (output_stream) 209 camel_object_unref (output_stream); 210 208 211 return; 209 212 trunk/libtinymail-camel/tny-camel-msg-header.c
r3235 r3249 77 77 ret = g_strdup (str); 78 78 } 79 80 if (ct) 81 camel_content_type_unref (ct); 82 79 83 return ret; 80 84 } 85 86 if (ct) 87 camel_content_type_unref (ct); 81 88 82 89 return camel_header_decode_string (str, charset); trunk/libtinymail-gnome-desktop/tny-gnome-device.c
r3247 r3249 219 219 #ifndef IMMEDIATE_ONLINE_TEST 220 220 priv->current_state = tny_gnome_device_is_online (TNY_DEVICE (self)); 221 if (priv->nm_ctx)222 priv->callback_id = libnm_glib_register_callback223 (priv->nm_ctx, nm_callback, self, NULL);221 //if (priv->nm_ctx) 222 // priv->callback_id = libnm_glib_register_callback 223 // (priv->nm_ctx, nm_callback, self, NULL); 224 224 #endif 225 225 #endif
