]> jfr.im git - irc/charybdis-ircd/charybdis.git/commitdiff
SJOIN: Fix crash when both mode parameter and UID list are missing. origin/release/3.4
authorJilles Tjoelker <redacted>
Fri, 15 Aug 2014 15:10:24 +0000 (17:10 +0200)
committerJilles Tjoelker <redacted>
Fri, 15 Aug 2014 20:01:58 +0000 (22:01 +0200)
Closes #63

(cherry picked from commit b733b9faf444746ae93150e2b64120954610db68)

modules/core/m_join.c

index 339aaa3a740d7ece812446de63e4fd423fbcb582..8542f123e0d4d7beba2e6ef5ee9be71d8d26ea1a 100644 (file)
@@ -537,6 +537,9 @@ ms_sjoin(struct Client *client_p, struct Client *source_p, int parc, const char
        static char empty[] = "";
        rb_dlink_node *ptr, *next_ptr;
 
+       if(parc < 5)
+               return 0;
+
        if(!IsChannelName(parv[2]) || !check_channel_name(parv[2]))
                return 0;