From 81d26e01cb0f918068f21e1b4c9bab5015a8a417 Mon Sep 17 00:00:00 2001 From: JP Rosevear Date: Sat, 15 Dec 2001 16:17:32 +0000 Subject: don't free the hash table keys, we didn't allocate them and free the 2001-12-15 JP Rosevear * conduit/address-conduit.c (e_addr_context_destroy): don't free the hash table keys, we didn't allocate them and free the change objects and unref the associated cards (local_record_from_uid): unref the temp card we create (replace_record): ref the new card associated with the card change and unref the old one svn path=/trunk/; revision=15091 --- addressbook/ChangeLog | 9 +++++++++ addressbook/conduit/address-conduit.c | 27 ++++++++++++++------------- 2 files changed, 23 insertions(+), 13 deletions(-) diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog index 3c7d97dbc8..f42f3a00fd 100644 --- a/addressbook/ChangeLog +++ b/addressbook/ChangeLog @@ -1,3 +1,12 @@ +2001-12-15 JP Rosevear + + * conduit/address-conduit.c (e_addr_context_destroy): don't free + the hash table keys, we didn't allocate them and free the change + objects and unref the associated cards + (local_record_from_uid): unref the temp card we create + (replace_record): ref the new card associated with the card change + and unref the old one + 2001-12-13 JP Rosevear * conduit/address-conduit.c (local_record_from_ecard): Make sure diff --git a/addressbook/conduit/address-conduit.c b/addressbook/conduit/address-conduit.c index 0c0645c2e9..6791d0e445 100644 --- a/addressbook/conduit/address-conduit.c +++ b/addressbook/conduit/address-conduit.c @@ -200,14 +200,6 @@ e_addr_context_new (guint32 pilot_id) return ctxt; } -static gboolean -e_addr_context_foreach_change (gpointer key, gpointer value, gpointer data) -{ - g_free (key); - - return TRUE; -} - static void e_addr_context_destroy (EAddrConduitContext *ctxt) { @@ -227,13 +219,20 @@ e_addr_context_destroy (EAddrConduitContext *ctxt) g_list_free (ctxt->cards); } - if (ctxt->changed_hash != NULL) { - g_hash_table_foreach_remove (ctxt->changed_hash, e_addr_context_foreach_change, NULL); + if (ctxt->changed_hash != NULL) g_hash_table_destroy (ctxt->changed_hash); - } - if (ctxt->changed != NULL) + if (ctxt->changed != NULL) { + CardObjectChange *coc; + + for (l = ctxt->changed; l != NULL; l = l->next) { + coc = l->data; + + gtk_object_unref (GTK_OBJECT (coc->card)); + g_free (coc); + } g_list_free (ctxt->changed); + } if (ctxt->locals != NULL) { for (l = ctxt->locals; l != NULL; l = l->next) @@ -827,6 +826,7 @@ local_record_from_uid (EAddrLocalRecord *local, ecard = e_card_new (""); e_card_set_id (ecard, uid); local_record_from_ecard (local, ecard, ctxt); + gtk_object_unref (GTK_OBJECT (ecard)); } } @@ -1397,9 +1397,10 @@ replace_record (GnomePilotConduitSyncAbs *conduit, coc = g_hash_table_lookup (ctxt->changed_hash, old_id); if (coc) { g_hash_table_remove (ctxt->changed_hash, e_card_get_id (coc->card)); + gtk_object_unref (GTK_OBJECT (coc->card)); + gtk_object_ref (GTK_OBJECT (local->ecard)); coc->card = local->ecard; g_hash_table_insert (ctxt->changed_hash, (gpointer)e_card_get_id (coc->card), coc); - } commit_status = cons.status; -- cgit /devel/electron6/files/elliptic-6.5.4'>dependabot/npm_and_yarn/devel/electron6/files/elliptic-6.5.4 FreeBSD GNOME current development ports (https://github.com/freebsd/freebsd-ports-gnome)
aboutsummaryrefslogtreecommitdiffstats
Commit message (Expand)AuthorAgeFilesLines
* Now installs again.kris2006-08-171-2/+0
* Mark BROKEN: does not installerwin2006-08-041-0/+2
* Update to 1.0itetcu2006-08-013-43/+107
* All dictionaries can be installed separately:thierry2006-07-154-7/+15
* Update to KDE 3.5.3lofi2006-06-064-22/+20
* Update to KOffice 1.5.1lofi2006-05-272-4/+4
* remove USE_REINPLACE for all categories starting with Hedwin2006-05-081-1/+0
* Update to KOffice 1.5.0lofi2006-04-293-5/+8
* Update to KDE 3.5.2lofi2006-03-314-128/+22
* Update to KDE 3.5.1.lofi2006-02-014-6/+20
* SHA256ifyedwin2006-01-227-0/+8
* Update to KDE 3.5.0lofi2006-01-094-110/+48
* Remove the usage of 'misc' as a secondary category.linimon2005-11-102-2/+2
* Update to KDE 3.4.3 / KOffice 1.4.2lofi2005-11-055-8/+7
* Remove all the secondary port of editors/ooodict-allmaho2005-11-012-21/+0
* Fix index build by moving openoffice.org-1.1 ports.maho2005-08-291-1/+1
* Update to KDE 3.4.2 / KOffice 1.4.1lofi2005-08-014-7/+7
* Update to KOffice 1.4.0a.lofi2005-07-063-30/+7
* Remove openoffice.org localized ports as I announced:maho2005-06-292-16/+0
* Update to KDE 3.4.1lofi2005-06-264-10/+4
* - Unbreak and general updatepav2005-06-061-2/+2
* Added slave port of lang/php_doc for the Hungarian languageedwin2005-05-232-0/+14
* - Update to 1.0.R.2pav2005-05-203-25/+10
* Update to KDE 3.4lofi2005-03-214-62/+270
* - Update MASTER_SITES, WWWpav2005-02-162-2/+2
* - Update MASTER_SITES, WWWpav2005-02-162-2/+2
* Add i18nized doc subdirs to kdehier and adjust i18n port plists accordingly.lofi2004-12-232-2/+0
* - Use new support for plugin ports from textproc/jdictionaryhq2004-12-194-47/+10
* Fix some more plist nits.lofi2004-12-173-3/+0
* Fix kde3-i18n ports.lofi2004-12-162-4/+4
* Update to KDE 3.3.2lofi2004-12-149-13/+16
* Update to KDE 3.3.1lofi2004-11-084-7/+7
* Update to KDE 3.3lofi2004-08-317-21/+133
* Add slaves ports for Aspell's new dictionaries.thierry2004-08-293-0/+22
* Factor out all but one of the build switches of the KDE main module portslofi2004-08-112-3/+3
* Update to 1.0.R.1arved2004-08-102-4/+4
* Update to 1.0 RC1arved2004-08-104-45/+53
* Update to version 3.2.3lofi2004-06-102-4/+4
* Add hunspell 0.9.7, improved Hungarian spelling checker.thierry2004-05-208-0/+169
* Oops. Forgot the language categories.lofi2004-05-072-3/+3
* Update to KDE 3.2.2lofi2004-04-204-40/+18
* Remove category pkg/COMMENT files in favour of a COMMENT variable in thekris2004-04-022-1/+3
* SIZEify (maintainer timeout)trevor2004-03-315-0/+5
* Add Hungarian version of OpenOffice.orgmaho2004-03-212-0/+16
* Reorder those filesmat2004-03-211-5/+5