mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-12 20:19:02 -04:00
Fixed a little overflow, noticed by satmd
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5621 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
parent
477b0cea88
commit
7cc96f2b1c
@ -1334,7 +1334,7 @@ const char* userrec::GetIPString()
|
||||
/* IP addresses starting with a : on irc are a Bad Thing (tm) */
|
||||
if (*buf == ':')
|
||||
{
|
||||
strlcpy(&temp[1], buf, sizeof(temp));
|
||||
strlcpy(&temp[1], buf, sizeof(temp) - 1);
|
||||
*temp = '0';
|
||||
return temp;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user