summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-12-17 17:41:53 +0000
committermichael <michael@82007160-df01-0410-b94d-b575c5fd34c7>2013-12-17 17:41:53 +0000
commit354d611659dee2b7fda6576920529f1df5bff617 (patch)
tree3d0546b92805ca3500b3f18a46f2bcdda2b43e45 /src
parentb189bc6db5e11b1dbe85de2a210aeda822e89bd2 (diff)
- introduce_client(), sendnick_TS(): fixed buffer overflow if a client has all possible
modes set that are defined in SEND_UMODES git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/branches/8.1.x@2687 82007160-df01-0410-b94d-b575c5fd34c7
Diffstat (limited to 'src')
-rw-r--r--src/s_serv.c2
-rw-r--r--src/s_user.c4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/s_serv.c b/src/s_serv.c
index 7c6fa2e..97ee59b 100644
--- a/src/s_serv.c
+++ b/src/s_serv.c
@@ -570,7 +570,7 @@ send_capabilities(struct Client *client_p, int cap_can_send)
void
sendnick_TS(struct Client *client_p, struct Client *target_p)
{
- static char ubuf[12];
+ char ubuf[66];
if (!IsClient(target_p))
return;
diff --git a/src/s_user.c b/src/s_user.c
index 30d54f9..7da24f8 100644
--- a/src/s_user.c
+++ b/src/s_user.c
@@ -563,7 +563,7 @@ static void
introduce_client(struct Client *source_p)
{
dlink_node *server_node = NULL;
- static char ubuf[12];
+ char ubuf[66];
if (MyClient(source_p))
send_umode(source_p, source_p, 0, SEND_UMODES, ubuf);
@@ -572,7 +572,7 @@ introduce_client(struct Client *source_p)
watch_check_hash(source_p, RPL_LOGON);
- if (*ubuf == '\0')
+ if (ubuf[0] == '\0')
{
ubuf[0] = '+';
ubuf[1] = '\0';