diff options
author | Milan Crha <mcrha@redhat.com> | 2012-04-23 19:34:56 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2012-04-23 19:34:56 +0800 |
commit | e2832731d2594be58d9581075dc25a9845893b1d (patch) | |
tree | 070a78b163e45476a20922f788607b8ed8810e18 | |
parent | c4c9ef784296760cf668d3e6a41d5869e4fd2c13 (diff) | |
download | gsoc2013-evolution-e2832731d2594be58d9581075dc25a9845893b1d.tar.gz gsoc2013-evolution-e2832731d2594be58d9581075dc25a9845893b1d.tar.zst gsoc2013-evolution-e2832731d2594be58d9581075dc25a9845893b1d.zip |
Bug #668543 - Crash in view_modify_contact_cb() if contact has no UID
-rw-r--r-- | addressbook/gui/widgets/e-addressbook-model.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/addressbook/gui/widgets/e-addressbook-model.c b/addressbook/gui/widgets/e-addressbook-model.c index bb8f2b59e3..18882489b6 100644 --- a/addressbook/gui/widgets/e-addressbook-model.c +++ b/addressbook/gui/widgets/e-addressbook-model.c @@ -278,6 +278,13 @@ view_modify_contact_cb (EBookClientView *client_view, gint ii; target_uid = e_contact_get_const (new_contact, E_CONTACT_UID); + g_warn_if_fail (target_uid != NULL); + + /* skip contacts without UID */ + if (!target_uid) { + contact_list = contact_list->next; + continue; + } for (ii = 0; ii < array->len; ii++) { EContact *old_contact; |