From 8e30839313a4b6322ba9f8ed0e787a7925aad760 Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Tue, 24 Sep 2013 14:03:06 +0100 Subject: [PATCH] TpConnection: don't crash if a broken CM has no Groups property Bug: https://bugs.freedesktop.org/show_bug.cgi?id=54500 --- telepathy-glib/connection-contact-list.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/telepathy-glib/connection-contact-list.c b/telepathy-glib/connection-contact-list.c index f00f230..5174819 100644 --- a/telepathy-glib/connection-contact-list.c +++ b/telepathy-glib/connection-contact-list.c @@ -614,7 +614,7 @@ prepare_contact_groups_cb (TpProxy *proxy, self->priv->contact_groups->len - 1); groups = tp_asv_get_boxed (properties, "Groups", G_TYPE_STRV); - for (iter = groups; *iter != NULL; iter++) + for (iter = groups; iter != NULL && *iter != NULL; iter++) { DEBUG (" %s", *iter); g_ptr_array_add (self->priv->contact_groups, g_strdup (*iter)); -- 1.8.4.rc3