Skip to content
Snippets Groups Projects
Commit ab3d76d0 authored by Jilles Tjoelker's avatar Jilles Tjoelker
Browse files

Fix crash with /os clearchan kick and kill.

The code had been wrong for a while, but 53ee43c7126f
makes it crash.
parent c8e4c65c
No related branches found
No related tags found
No related merge requests found
......@@ -45,7 +45,7 @@ void _moddeinit(void)
static void os_cmd_clearchan(sourceinfo_t *si, int parc, char *parv[])
{
chanuser_t *cu = NULL;
node_t *n = NULL;
node_t *n, *tn;
channel_t *c = NULL;
int action;
char *actionstr = parv[0];
......@@ -101,7 +101,7 @@ static void os_cmd_clearchan(sourceinfo_t *si, int parc, char *parv[])
command_success_nodata(si, _("Clearing \2%s\2 with \2%s\2"), targchan, actionstr);
/* iterate over the users in channel */
LIST_FOREACH(n, c->members.head)
LIST_FOREACH_SAFE(n, tn, c->members.head)
{
cu = n->data;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment