Use strlcat, rather than strmcat, in ignore_list().
git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@400 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
@@ -408,159 +408,159 @@ static void ignore_list(char *nick)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (tmp->type & IGNORE_PUBLIC)
|
if (tmp->type & IGNORE_PUBLIC)
|
||||||
strmcat(buffer, " PUBLIC", BIG_BUFFER_SIZE);
|
strlcat(buffer, " PUBLIC", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_PUBLIC)
|
else if (tmp->high & IGNORE_PUBLIC)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "PUBLIC", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "PUBLIC", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_PUBLIC)
|
else if (tmp->dont & IGNORE_PUBLIC)
|
||||||
strmcat(buffer, " DONT-PUBLIC", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-PUBLIC", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_MSGS)
|
if (tmp->type & IGNORE_MSGS)
|
||||||
strmcat(buffer, " MSGS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " MSGS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_MSGS)
|
else if (tmp->high & IGNORE_MSGS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "MSG", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "MSG", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_MSGS)
|
else if (tmp->dont & IGNORE_MSGS)
|
||||||
strmcat(buffer, " DONT-MSGS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-MSGS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_WALLS)
|
if (tmp->type & IGNORE_WALLS)
|
||||||
strmcat(buffer, " WALLS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " WALLS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_WALLS)
|
else if (tmp->high & IGNORE_WALLS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "WALL", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "WALL", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_WALLS)
|
else if (tmp->dont & IGNORE_WALLS)
|
||||||
strmcat(buffer, " DONT-WALLS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-WALLS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_WALLOPS)
|
if (tmp->type & IGNORE_WALLOPS)
|
||||||
strmcat(buffer, " WALLOPS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " WALLOPS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_WALLOPS)
|
else if (tmp->high & IGNORE_WALLOPS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "WALLOPS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "WALLOPS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_WALLOPS)
|
else if (tmp->dont & IGNORE_WALLOPS)
|
||||||
strmcat(buffer, " DONT-WALLOPS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-WALLOPS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_INVITES)
|
if (tmp->type & IGNORE_INVITES)
|
||||||
strmcat(buffer, " INVITES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " INVITES", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_INVITES)
|
else if (tmp->high & IGNORE_INVITES)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "INVITES", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "INVITES", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_INVITES)
|
else if (tmp->dont & IGNORE_INVITES)
|
||||||
strmcat(buffer, " DONT-INVITES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-INVITES", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_NOTICES)
|
if (tmp->type & IGNORE_NOTICES)
|
||||||
strmcat(buffer, " NOTICES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " NOTICES", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_NOTICES)
|
else if (tmp->high & IGNORE_NOTICES)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "NOTICES", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "NOTICES", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_NOTICES)
|
else if (tmp->dont & IGNORE_NOTICES)
|
||||||
strmcat(buffer, " DONT-NOTICES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-NOTICES", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_NOTES)
|
if (tmp->type & IGNORE_NOTES)
|
||||||
strmcat(buffer, " NOTES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " NOTES", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_NOTES)
|
else if (tmp->high & IGNORE_NOTES)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "NOTES", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "NOTES", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_NOTES)
|
else if (tmp->dont & IGNORE_NOTES)
|
||||||
strmcat(buffer, " DONT-NOTES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-NOTES", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_CTCPS)
|
if (tmp->type & IGNORE_CTCPS)
|
||||||
strmcat(buffer, " CTCPS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " CTCPS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_CTCPS)
|
else if (tmp->high & IGNORE_CTCPS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "CTCPS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "CTCPS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_CTCPS)
|
else if (tmp->dont & IGNORE_CTCPS)
|
||||||
strmcat(buffer, " DONT-CTCPS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-CTCPS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_CDCC)
|
if (tmp->type & IGNORE_CDCC)
|
||||||
strmcat(buffer, " CDCC", BIG_BUFFER_SIZE);
|
strlcat(buffer, " CDCC", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_CDCC)
|
else if (tmp->high & IGNORE_CDCC)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "CDCC", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "CDCC", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_CDCC)
|
else if (tmp->dont & IGNORE_CDCC)
|
||||||
strmcat(buffer, " DONT-CDCC", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-CDCC", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_KICKS)
|
if (tmp->type & IGNORE_KICKS)
|
||||||
strmcat(buffer, " KICKS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " KICKS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_KICKS)
|
else if (tmp->high & IGNORE_KICKS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "KICKS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "KICKS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_KICKS)
|
else if (tmp->dont & IGNORE_KICKS)
|
||||||
strmcat(buffer, " DONT-KICKS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-KICKS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_MODES)
|
if (tmp->type & IGNORE_MODES)
|
||||||
strmcat(buffer, " MODES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " MODES", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_MODES)
|
else if (tmp->high & IGNORE_MODES)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "MODES", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "MODES", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_MODES)
|
else if (tmp->dont & IGNORE_MODES)
|
||||||
strmcat(buffer, " DONT-MODES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-MODES", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_SMODES)
|
if (tmp->type & IGNORE_SMODES)
|
||||||
strmcat(buffer, " SMODES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " SMODES", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_SMODES)
|
else if (tmp->high & IGNORE_SMODES)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "SMODES", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "SMODES", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_SMODES)
|
else if (tmp->dont & IGNORE_SMODES)
|
||||||
strmcat(buffer, " DONT-SMODES", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-SMODES", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_JOINS)
|
if (tmp->type & IGNORE_JOINS)
|
||||||
strmcat(buffer, " JOINS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " JOINS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_JOINS)
|
else if (tmp->high & IGNORE_JOINS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "JOINS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "JOINS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_JOINS)
|
else if (tmp->dont & IGNORE_JOINS)
|
||||||
strmcat(buffer, " DONT-JOINS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-JOINS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_TOPICS)
|
if (tmp->type & IGNORE_TOPICS)
|
||||||
strmcat(buffer, " TOPICS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " TOPICS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_TOPICS)
|
else if (tmp->high & IGNORE_TOPICS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "TOPICS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "TOPICS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_TOPICS)
|
else if (tmp->dont & IGNORE_TOPICS)
|
||||||
strmcat(buffer, " DONT-TOPICS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-TOPICS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_QUITS)
|
if (tmp->type & IGNORE_QUITS)
|
||||||
strmcat(buffer, " QUITS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " QUITS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_QUITS)
|
else if (tmp->high & IGNORE_QUITS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "QUITS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE,space, highlight_char, "QUITS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_QUITS)
|
else if (tmp->dont & IGNORE_QUITS)
|
||||||
strmcat(buffer, " DONT-QUITS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-QUITS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_PARTS)
|
if (tmp->type & IGNORE_PARTS)
|
||||||
strmcat(buffer, " PARTS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " PARTS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_PARTS)
|
else if (tmp->high & IGNORE_PARTS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "PARTS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "PARTS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_PARTS)
|
else if (tmp->dont & IGNORE_PARTS)
|
||||||
strmcat(buffer, " DONT-PARTS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-PARTS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_NICKS)
|
if (tmp->type & IGNORE_NICKS)
|
||||||
strmcat(buffer, " NICKS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " NICKS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_NICKS)
|
else if (tmp->high & IGNORE_NICKS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "NICKS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "NICKS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_NICKS)
|
else if (tmp->dont & IGNORE_NICKS)
|
||||||
strmcat(buffer, " DONT-NICKS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-NICKS", sizeof buffer);
|
||||||
|
|
||||||
|
|
||||||
if (tmp->type & IGNORE_PONGS)
|
if (tmp->type & IGNORE_PONGS)
|
||||||
strmcat(buffer, " PONGS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " PONGS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_PONGS)
|
else if (tmp->high & IGNORE_PONGS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "PONGS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "PONGS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_PONGS)
|
else if (tmp->dont & IGNORE_PONGS)
|
||||||
strmcat(buffer, " DONT-PONGS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-PONGS", sizeof buffer);
|
||||||
|
|
||||||
|
|
||||||
if (tmp->type & IGNORE_SPLITS)
|
if (tmp->type & IGNORE_SPLITS)
|
||||||
strmcat(buffer, " SPLITS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " SPLITS", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_SPLITS)
|
else if (tmp->high & IGNORE_SPLITS)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "SPLITS", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "SPLITS", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_SPLITS)
|
else if (tmp->dont & IGNORE_SPLITS)
|
||||||
strmcat(buffer, " DONT-SPLITS", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-SPLITS", sizeof buffer);
|
||||||
|
|
||||||
if (tmp->type & IGNORE_CRAP)
|
if (tmp->type & IGNORE_CRAP)
|
||||||
strmcat(buffer, " CRAP", BIG_BUFFER_SIZE);
|
strlcat(buffer, " CRAP", sizeof buffer);
|
||||||
else if (tmp->high & IGNORE_CRAP)
|
else if (tmp->high & IGNORE_CRAP)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "CRAP", highlight_char, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, space, highlight_char, "CRAP", highlight_char, NULL);
|
||||||
else if (tmp->dont & IGNORE_CRAP)
|
else if (tmp->dont & IGNORE_CRAP)
|
||||||
strmcat(buffer, " DONT-CRAP", BIG_BUFFER_SIZE);
|
strlcat(buffer, " DONT-CRAP", sizeof buffer);
|
||||||
|
|
||||||
}
|
}
|
||||||
if (tmp->except)
|
if (tmp->except)
|
||||||
{
|
{
|
||||||
Ignore *new;
|
Ignore *new;
|
||||||
strmcat(buffer, " EXCEPT ", BIG_BUFFER_SIZE);
|
strlcat(buffer, " EXCEPT ", sizeof buffer);
|
||||||
for (new = tmp->except; new; new = new->next)
|
for (new = tmp->except; new; new = new->next)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, new->nick, space, NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, new->nick, space, NULL);
|
||||||
}
|
}
|
||||||
if (tmp->looking && tmp->cgrep)
|
if (tmp->looking && tmp->cgrep)
|
||||||
{
|
{
|
||||||
Ignore *new;
|
Ignore *new;
|
||||||
strmcat(buffer, " CGREP ", BIG_BUFFER_SIZE);
|
strlcat(buffer, " CGREP ", sizeof buffer);
|
||||||
for (new = tmp->looking; new; new = new->next)
|
for (new = tmp->looking; new; new = new->next)
|
||||||
strmopencat(buffer, BIG_BUFFER_SIZE, "[", new->nick, "] ", NULL);
|
strmopencat(buffer, BIG_BUFFER_SIZE, "[", new->nick, "] ", NULL);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user