gatchat: quit early if the group id doesn't match

If the ID of the notify matches but the group id does not match it means
that the unregister is being called with an id that does not belong to
that particular group.  Checking further entries is no longer necessary.
This commit is contained in:
Denis Kenzior 2010-10-14 06:58:53 -05:00
parent 37d2edec1c
commit 7fd86cf94f
1 changed files with 1 additions and 1 deletions

View File

@ -1085,7 +1085,7 @@ static gboolean at_chat_unregister(struct at_chat *chat, guint group, guint id)
node = l->data;
if (node->gid != group)
continue;
return FALSE;
at_notify_node_destroy(node, NULL);
notify->nodes = g_slist_remove(notify->nodes, node);