Merge branch 'security' into 'master'

See merge request !7
This commit is contained in:
ailin-nemui 2017-01-03 13:44:58 +01:00
commit 6c6c42e3d1
4 changed files with 26 additions and 5 deletions

View file

@ -314,7 +314,11 @@ static void event_whois_ircop(SERVER_REC *server, const char *data)
static void event_nick_invalid(IRC_SERVER_REC *server, const char *data)
{
if (!server->connected)
server_disconnect((SERVER_REC *) server);
/* we used to call server_disconnect but that crashes
irssi because of undefined memory access. instead,
indicate that the connection should be dropped and
let the irc method to the clean-up. */
server->connection_lost = server->no_reconnect = TRUE;
}
static void event_nick_in_use(IRC_SERVER_REC *server, const char *data)

View file

@ -45,6 +45,8 @@ QUERY_REC *irc_query_find(IRC_SERVER_REC *server, const char *nick)
{
GSList *tmp;
g_return_val_if_fail(nick != NULL, NULL);
for (tmp = server->queries; tmp != NULL; tmp = tmp->next) {
QUERY_REC *rec = tmp->data;