diff options
author | JP Rosevear <jpr@ximian.com> | 2001-08-20 21:24:25 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2001-08-20 21:24:25 +0800 |
commit | 1892a4df857e4f1c236c108b685ffe7d87e85cee (patch) | |
tree | eda9411718223d25c6f411e60ea25635d6f06f4a /addressbook/conduit/address-conduit.c | |
parent | 85f3f150b2b57a691357af4f2420f174d127c340 (diff) | |
download | gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.tar gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.tar.gz gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.tar.bz2 gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.tar.lz gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.tar.xz gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.tar.zst gsoc2013-evolution-1892a4df857e4f1c236c108b685ffe7d87e85cee.zip |
fix warnings, get compiling again
2001-08-20 JP Rosevear <jpr@ximian.com>
* conduit/address-conduit.c: fix warnings, get compiling again
* conduit/address-conduit-config.h: remove c/p typos
* conduit/address-conduit.h: ditto
* conduit/Makefile.am: link against the static camel
svn path=/trunk/; revision=12288
Diffstat (limited to 'addressbook/conduit/address-conduit.c')
-rw-r--r-- | addressbook/conduit/address-conduit.c | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/addressbook/conduit/address-conduit.c b/addressbook/conduit/address-conduit.c index 61917cc00f..ca0530033d 100644 --- a/addressbook/conduit/address-conduit.c +++ b/addressbook/conduit/address-conduit.c @@ -407,14 +407,22 @@ local_record_from_ecard (EAddrLocalRecord *local, ECard *ecard, EAddrConduitCont static void local_record_from_uid (EAddrLocalRecord *local, - char *uid, + const char *uid, EAddrConduitContext *ctxt) { ECard *ecard = NULL; - + GList *l; + g_assert (local != NULL); - ecard = e_book_get_card (ctxt->ebook, uid); + for (l = ctxt->cards; l != NULL; l = l->next) { + ecard = l->data; + + if (ecard->id && !strcmp (ecard->id, uid)) + break; + + ecard = NULL; + } if (ecard != NULL) { local_record_from_ecard (local, ecard, ctxt); @@ -565,7 +573,7 @@ card_added (EBookView *book_view, const GList *cards, EAddrConduitContext *ctxt) gtk_object_ref (GTK_OBJECT (coc->card)); ctxt->changed = g_list_prepend (ctxt->changed, coc); if (!e_pilot_map_uid_is_archived (ctxt->map, e_card_get_id (coc->card))) - g_hash_table_insert (ctxt->changed_hash, e_card_get_id (coc->card), coc); + g_hash_table_insert (ctxt->changed_hash, (gpointer)e_card_get_id (coc->card), coc); } } @@ -583,7 +591,7 @@ card_changed (EBookView *book_view, const GList *cards, EAddrConduitContext *ctx gtk_object_ref (GTK_OBJECT (coc->card)); ctxt->changed = g_list_prepend (ctxt->changed, coc); if (!e_pilot_map_uid_is_archived (ctxt->map, e_card_get_id (coc->card))) - g_hash_table_insert (ctxt->changed_hash, e_card_get_id (coc->card), coc); + g_hash_table_insert (ctxt->changed_hash, (gpointer)e_card_get_id (coc->card), coc); } } @@ -599,7 +607,7 @@ card_removed (EBookView *book_view, const char *id, EAddrConduitContext *ctxt) ctxt->changed = g_list_prepend (ctxt->changed, coc); if (!e_pilot_map_uid_is_archived (ctxt->map, id)) - g_hash_table_insert (ctxt->changed_hash, e_card_get_id (coc->card), coc); + g_hash_table_insert (ctxt->changed_hash, (gpointer)e_card_get_id (coc->card), coc); } static void @@ -951,7 +959,7 @@ replace_record (GnomePilotConduitSyncAbs *conduit, if (coc) { g_hash_table_remove (ctxt->changed_hash, e_card_get_id (coc->card)); coc->card = local->ecard; - g_hash_table_insert (ctxt->changed_hash, e_card_get_id (coc->card), coc); + g_hash_table_insert (ctxt->changed_hash, (gpointer)e_card_get_id (coc->card), coc); } @@ -1011,7 +1019,7 @@ match (GnomePilotConduitSyncAbs *conduit, EAddrLocalRecord **local, EAddrConduitContext *ctxt) { - char *uid; + const char *uid; LOG ("match: looking for local copy of %s\n", print_remote (remote)); |