applied clamiax' patch for null messages

This commit is contained in:
Anselm R Garbe 2009-10-30 09:34:59 +00:00
parent 7f1961d4c6
commit 9c7027fcbf
1 changed files with 2 additions and 3 deletions

5
sic.c
View File

@ -73,9 +73,8 @@ parsein(char *msg) {
snprintf(bufout, sizeof bufout, "JOIN %s\r\n", msg + 3);
else if(strncmp(msg + 1, "l ", 2) == 0)
snprintf(bufout, sizeof bufout, "PART %s :sic - 250 LOC are too much!\r\n", msg + 3);
else if(strncmp(msg + 1, "m ", 2) == 0) {
if((p = strchr(msg + 3, ' ')))
*(p++) = '\0';
else if(strncmp(msg + 1, "m ", 2) == 0 && (p = strchr(msg + 3, ' '))) {
*(p++) = '\0';
privmsg(msg + 3, p);
return;
}