[svn] Cut down quit/part/kick reasons to avoid quit reasons
overflowing the client exiting server notice (from TOPICLEN to 260). kill reasons become shorter accordingly. kline/dline/gline reasons become 390. away messages stay at TOPICLEN for now.
This commit is contained in:
parent
606384aea8
commit
61569b65f2
6 changed files with 34 additions and 19 deletions
|
@ -21,7 +21,7 @@
|
|||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
||||
* USA
|
||||
*
|
||||
* $Id: m_dline.c 3161 2007-01-25 07:23:01Z nenolod $
|
||||
* $Id: m_dline.c 3225 2007-03-04 23:42:55Z jilles $
|
||||
*/
|
||||
|
||||
#include "stdinc.h"
|
||||
|
@ -59,7 +59,7 @@ struct Message undline_msgtab = {
|
|||
};
|
||||
|
||||
mapi_clist_av1 dline_clist[] = { &dline_msgtab, &undline_msgtab, NULL };
|
||||
DECLARE_MODULE_AV1(dline, NULL, NULL, dline_clist, NULL, NULL, "$Revision: 3161 $");
|
||||
DECLARE_MODULE_AV1(dline, NULL, NULL, dline_clist, NULL, NULL, "$Revision: 3225 $");
|
||||
|
||||
static int valid_comment(char *comment);
|
||||
static int flush_write(struct Client *, FILE *, char *, char *);
|
||||
|
@ -393,8 +393,8 @@ valid_comment(char *comment)
|
|||
if(strchr(comment, '"'))
|
||||
return 0;
|
||||
|
||||
if(strlen(comment) > REASONLEN)
|
||||
comment[REASONLEN] = '\0';
|
||||
if(strlen(comment) > BANREASONLEN)
|
||||
comment[BANREASONLEN] = '\0';
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
||||
* USA
|
||||
*
|
||||
* $Id: m_gline.c 3161 2007-01-25 07:23:01Z nenolod $
|
||||
* $Id: m_gline.c 3225 2007-03-04 23:42:55Z jilles $
|
||||
*/
|
||||
|
||||
#include "stdinc.h"
|
||||
|
@ -63,7 +63,7 @@ struct Message ungline_msgtab = {
|
|||
};
|
||||
|
||||
mapi_clist_av1 gline_clist[] = { &gline_msgtab, &ungline_msgtab, NULL };
|
||||
DECLARE_MODULE_AV1(gline, NULL, NULL, gline_clist, NULL, NULL, "$Revision: 3161 $");
|
||||
DECLARE_MODULE_AV1(gline, NULL, NULL, gline_clist, NULL, NULL, "$Revision: 3225 $");
|
||||
|
||||
static int majority_gline(struct Client *source_p, const char *user,
|
||||
const char *host, const char *reason);
|
||||
|
@ -514,8 +514,8 @@ invalid_gline(struct Client *source_p, const char *luser,
|
|||
return 1;
|
||||
}
|
||||
|
||||
if(strlen(lreason) > REASONLEN)
|
||||
lreason[REASONLEN] = '\0';
|
||||
if(strlen(lreason) > BANREASONLEN)
|
||||
lreason[BANREASONLEN] = '\0';
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
@ -546,8 +546,8 @@ set_local_gline(struct Client *source_p, const char *user,
|
|||
aconf->status = CONF_GLINE;
|
||||
aconf->flags |= CONF_FLAGS_TEMPORARY;
|
||||
|
||||
if(strlen(my_reason) > REASONLEN)
|
||||
my_reason[REASONLEN-1] = '\0';
|
||||
if(strlen(my_reason) > BANREASONLEN)
|
||||
my_reason[BANREASONLEN-1] = '\0';
|
||||
|
||||
if((oper_reason = strchr(my_reason, '|')) != NULL)
|
||||
{
|
||||
|
|
|
@ -21,7 +21,7 @@
|
|||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
|
||||
* USA
|
||||
*
|
||||
* $Id: m_kline.c 3161 2007-01-25 07:23:01Z nenolod $
|
||||
* $Id: m_kline.c 3225 2007-03-04 23:42:55Z jilles $
|
||||
*/
|
||||
|
||||
#include "stdinc.h"
|
||||
|
@ -65,7 +65,7 @@ struct Message unkline_msgtab = {
|
|||
};
|
||||
|
||||
mapi_clist_av1 kline_clist[] = { &kline_msgtab, &unkline_msgtab, NULL };
|
||||
DECLARE_MODULE_AV1(kline, NULL, NULL, kline_clist, NULL, NULL, "$Revision: 3161 $");
|
||||
DECLARE_MODULE_AV1(kline, NULL, NULL, kline_clist, NULL, NULL, "$Revision: 3225 $");
|
||||
|
||||
/* Local function prototypes */
|
||||
static int find_user_host(struct Client *source_p, const char *userhost, char *user, char *host);
|
||||
|
@ -659,8 +659,8 @@ valid_comment(struct Client *source_p, char *comment)
|
|||
return 0;
|
||||
}
|
||||
|
||||
if(strlen(comment) > REASONLEN)
|
||||
comment[REASONLEN] = '\0';
|
||||
if(strlen(comment) > BANREASONLEN)
|
||||
comment[BANREASONLEN] = '\0';
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue