Fix previous commit and parsing of ipmasks like 127/8.
[ircu2.10.12-pk.git] / ircd / m_join.c
index ad412956a64285c8e3aeb61e62511994fb336b09..f230beb07219d0c0656ff97de23e373dd2c81fc8 100644 (file)
@@ -132,7 +132,7 @@ int m_join(struct Client *cptr, struct Client *sptr, int parc, char *parv[])
       *keys++ = '\0';
 
     /* Empty keys are the same as no keys. */
-    if (!key[0])
+    if (key && !key[0])
       key = 0;
 
     clean_channelname(name);