#define HCHANNEL_CONF_COUNT 21
+#define HCHANNEL_WELCOME_LEN 400
+
typedef struct hchannel_struct
{
channel *real_channel;
- char welcome[400];
+ char welcome[HCHANNEL_WELCOME_LEN];
int flags;
int jf_control; /* join flood control */
#include <sys/types.h>
#include <dirent.h>
+#include "../lib/strlfunc.h"
+
#include "hcommands.h"
#include "hcommand.h"
}
else
{
- strcpy(hchan->welcome, ostr);
+ strlcpy(hchan->welcome, ostr, HCHANNEL_WELCOME_LEN);
helpmod_reply(sender, returntype, "Welcome message for channel %s (%s) is now: %s", hchan->real_channel->index->name->content, hchannel_get_state(hchan, H_WELCOME), hchan->welcome);
}
}