monitor: ensure monitored nicknames are valid (ref. elemental-ircd/elemental-ircd#187)

This commit is contained in:
William Pitcock 2015-12-12 08:42:03 -06:00
parent 72dee03d50
commit 413c61aaf5

View file

@ -114,6 +114,9 @@ add_monitor(struct Client *client_p, const char *nicks)
return; return;
} }
if (!is_valid_nick(name))
continue;
monptr = find_monitor(name, 1); monptr = find_monitor(name, 1);
/* already monitoring this nick */ /* already monitoring this nick */