From: <dg...@su...> - 2009-01-25 13:01:45
|
Author: paule Date: Sun Jan 25 14:00:26 2009 New Revision: 5230 URL: http://www.opensync.org/changeset/5230 Log: Add explicit check that a UID could be retrieved, in case of entries on the device written by other software without one (!) Modified: plugins/opie-sync/src/opie_sync.c Modified: plugins/opie-sync/src/opie_sync.c ============================================================================== --- plugins/opie-sync/src/opie_sync.c Sun Jan 25 13:47:14 2009 (r5229) +++ plugins/opie-sync/src/opie_sync.c Sun Jan 25 14:00:26 2009 (r5230) @@ -347,6 +347,10 @@ /* Retrieve and set the uid of the object */ char *uid = opie_xml_get_tagged_uid(item_node); + if(!uid) { + osync_trace(TRACE_EXIT_ERROR, "%s: unable to get UID from entry"); + return; + } osync_change_set_uid(change, uid); g_free(uid); |