-/* ChanNode.c - NeonServ v5.5
+/* ChanNode.c - NeonServ v5.6
* Copyright (C) 2011-2012 Philipp Kreil (pk910)
*
* This program is free software: you can redistribute it and/or modify
#include "modcmd.h"
#include "ModeNode.h"
#include "IRCEvents.h"
+#include "tools.h"
+#include "log.h"
static struct ChanNode **chanList;
struct ChanNode *chan = malloc(sizeof(*chan));
if (!chan)
{
- perror("malloc() failed");
+ printf_log("main", LOG_ERROR, "%s:%d malloc() failed", __FILE__, __LINE__);
return NULL;
}
strcpy(chan->name, name);
chan->bans = NULL;
chan->spam_settings = NULL;
chan->usercount = 0;
+ chan->botcount = 0;
chan->topic[0] = 0;
chan->flags = 0;
/* mode lists */