aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJP Rosevear <jpr@helixcode.com>2000-12-21 02:18:40 +0800
committerJP Rosevear <jpr@src.gnome.org>2000-12-21 02:18:40 +0800
commit0380a5d85e1039d711a868356103f2feec4fd7de (patch)
tree7e7435b6160da13627f3619a5a09446342197944
parentf055dfa7c861b6ed806a1a694f19574891e053ba (diff)
downloadgsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.tar
gsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.tar.gz
gsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.tar.bz2
gsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.tar.lz
gsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.tar.xz
gsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.tar.zst
gsoc2013-evolution-0380a5d85e1039d711a868356103f2feec4fd7de.zip
Use my own wrapper functions instead of trying to *directly* access the
2000-12-20 JP Rosevear <jpr@helixcode.com> * conduit/address-conduit.c (match): Use my own wrapper functions instead of trying to *directly* access the the data structures my self (post_sync): Put in hack to prevent syncing the same records twice svn path=/trunk/; revision=7104
-rw-r--r--addressbook/ChangeLog9
-rw-r--r--addressbook/conduit/address-conduit.c11
2 files changed, 17 insertions, 3 deletions
diff --git a/addressbook/ChangeLog b/addressbook/ChangeLog
index 88b7961580..c566b860de 100644
--- a/addressbook/ChangeLog
+++ b/addressbook/ChangeLog
@@ -1,6 +1,13 @@
+2000-12-20 JP Rosevear <jpr@helixcode.com>
+
+ * conduit/address-conduit.c (match): Use my own wrapper
+ functions instead of trying to *directly* access the the data
+ structures my self
+ (post_sync): Put in hack to prevent syncing the same records twice
+
2000-12-19 JP Rosevear <jpr@helixcode.com>
- *conduit/address-conduit.c (ecard_from_remote_record): Convert
+ * conduit/address-conduit.c (ecard_from_remote_record): Convert
pilot strings to utf for the e-cards.
2000-12-19 JP Rosevear <jpr@helixcode.com>
diff --git a/addressbook/conduit/address-conduit.c b/addressbook/conduit/address-conduit.c
index 909e4b20a9..8208d2ba8f 100644
--- a/addressbook/conduit/address-conduit.c
+++ b/addressbook/conduit/address-conduit.c
@@ -652,7 +652,7 @@ post_sync (GnomePilotConduit *conduit,
GnomePilotDBInfo *dbi,
EAddrConduitContext *ctxt)
{
- gchar *filename;
+ gchar *filename, *change_id;
LOG ("post_sync: Address Conduit v.%s", CONDUIT_VERSION);
LOG ("---------------------------------------------------------\n");
@@ -660,6 +660,13 @@ post_sync (GnomePilotConduit *conduit,
filename = map_name (ctxt);
e_pilot_map_write (filename, ctxt->map);
g_free (filename);
+
+ /* FIX ME ugly hack - our changes musn't count, this does introduce
+ * a race condition if anyone changes a record elsewhere during sycnc
+ */
+ change_id = g_strdup_printf ("pilot-sync-evolution-addressbook-%d", ctxt->cfg->pilot_id);
+ e_book_get_changes (ctxt->ebook, change_id, view_cb, ctxt);
+ g_free (change_id);
return 0;
}
@@ -939,7 +946,7 @@ match (GnomePilotConduitSyncAbs *conduit,
g_return_val_if_fail (remote != NULL, -1);
*local = NULL;
- uid = g_hash_table_lookup (ctxt->map->pid_map, &remote->ID);
+ uid = e_pilot_map_lookup_uid (ctxt->map, remote->ID);
if (!uid)
return 0;