summaryrefslogtreecommitdiff
path: root/src/channels.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-09-11 20:10:05 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2004-09-11 20:10:05 +0000
commite7f0a0fb7edf96abbddf72eadb490b5eb22447ec (patch)
tree67c9bfeadf64d1622e8ed060a55969ddb6452834 /src/channels.cpp
parentea36f2bb1b8b1bf03b8615672866f93697caff75 (diff)
Security audit based on RATS output
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@855 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/channels.cpp')
-rw-r--r--src/channels.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/channels.cpp b/src/channels.cpp
index 4bec1bcdb..0995a2eaa 100644
--- a/src/channels.cpp
+++ b/src/channels.cpp
@@ -127,7 +127,7 @@ void chanrec::SetCustomMode(char mode,bool mode_on)
m[1] = '\0';
if (!strchr(this->custom_modes,mode))
{
- strncat(custom_modes,m,MAXMODES);
+ strlcat(custom_modes,m,MAXMODES);
}
log(DEBUG,"Custom mode %c set",mode);
}
@@ -150,8 +150,8 @@ void chanrec::SetCustomModeParam(char mode,char* parameter,bool mode_on)
log(DEBUG,"SetCustomModeParam called");
ModeParameter M;
M.mode = mode;
- strcpy(M.channel,this->name);
- strcpy(M.parameter,parameter);
+ strlcpy(M.channel,this->name,CHANMAX);
+ strlcpy(M.parameter,parameter,MAXBUF);
if (mode_on)
{
log(DEBUG,"Custom mode parameter %c %s added",mode,parameter);