summaryrefslogtreecommitdiffstats
path: root/gatchat/gatchat.c
diff options
context:
space:
mode:
authorDenis Kenzior <denkenz@gmail.com>2010-10-14 06:58:53 -0500
committerDenis Kenzior <denkenz@gmail.com>2010-10-14 09:42:42 -0500
commit7fd86cf94f40b990765e43d9a320c71cfde82aac (patch)
treebc801d5743d48fa5b7e7b2f1fc946f3ce7963451 /gatchat/gatchat.c
parent37d2edec1cf1cbc1d99293aa74bd1c8b0e21709c (diff)
downloadofono-7fd86cf94f40b990765e43d9a320c71cfde82aac.tar.bz2
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.
Diffstat (limited to 'gatchat/gatchat.c')
-rw-r--r--gatchat/gatchat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/gatchat/gatchat.c b/gatchat/gatchat.c
index e85d9086..cfe21887 100644
--- a/gatchat/gatchat.c
+++ b/gatchat/gatchat.c
@@ -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);