summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Janouch <p@janouch.name>2018-08-01 09:21:37 +0200
committerPřemysl Janouch <p@janouch.name>2018-08-01 09:21:37 +0200
commit50ed74a740d8e9be5948f9f11fb1a720c83dd38c (patch)
treea9c2856a65308a2aacfd0b7eee5f1fea01debe9f
parent3ca08badc288df7ea2d253b8232d767ec38b558e (diff)
downloadxK-50ed74a740d8e9be5948f9f11fb1a720c83dd38c.tar.gz
xK-50ed74a740d8e9be5948f9f11fb1a720c83dd38c.tar.xz
xK-50ed74a740d8e9be5948f9f11fb1a720c83dd38c.zip
kike: break out properly on errors in MODE processing
We used to only abort the inner loop, which was insufficient.
-rw-r--r--kike.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/kike.c b/kike.c
index baa141f..68bcdcd 100644
--- a/kike.c
+++ b/kike.c
@@ -2006,10 +2006,11 @@ irc_handle_chan_mode_change
mode_processor_step (&p, '+');
while (*mode_string)
if (!mode_processor_step (&p, *mode_string++))
- break;
+ goto done_processing;
}
// TODO: limit to three changes with parameter per command
+done_processing:
if (p.added.len || p.removed.len)
{
struct str message = str_make ();