svn: 1219
@@ -192,7 +192,7 @@ struct chanset_t {
*/
char topic[121];
char added_by[NICKLEN]; /* who added the channel? */
- char floodwho[FLOOD_CHAN_MAX][81];
+ char floodwho[FLOOD_CHAN_MAX][128];
char deopd[NICKLEN]; /* last person deop'd (must change */
char dname[81]; /* what the users know the channel as like !eggdev */
char name[81]; /* what the servers know the channel as, like !ABCDEeggdev */
@@ -34,8 +34,8 @@ int sdebug = 0; /* enable debug output? */
#ifdef DEBUG_CONTEXT
/* Context storage for fatal crashes */
-char cx_file[16][15];
-char cx_note[16][21];
+char cx_file[16][16];
+char cx_note[16][16];
int cx_line[16] = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
int cx_ptr = 0;
#endif /* DEBUG_CONTEXT */
@@ -408,8 +408,8 @@ static int detect_chan_flood(char *floodnick, char *floodhost, char *from,
return 0;
}
if (rfc_casecmp(chan->floodwho[which], p)) { /* new */
- strncpy(chan->floodwho[which], p, 81);
- chan->floodwho[which][81] = 0;
+ strncpy(chan->floodwho[which], p, sizeof(chan->floodwho[which]));
+ chan->floodwho[which][sizeof(chan->floodwho[which])] = 0;
chan->floodtime[which] = now;
chan->floodnum[which] = 1;
@@ -321,7 +321,7 @@ void nuke_server(char *reason)
char ctcp_reply[1024] = "";
static int lastmsgs[FLOOD_GLOBAL_MAX];
-static char lastmsghost[FLOOD_GLOBAL_MAX][81];
+static char lastmsghost[FLOOD_GLOBAL_MAX][128];
static time_t lastmsgtime[FLOOD_GLOBAL_MAX];
/* Do on NICK, PRIVMSG, NOTICE and JOIN.