mirror of
https://github.com/osmarks/ngircd.git
synced 2025-11-11 19:23:01 +00:00
irc-info.c: Use strlcpy() instead of strcpy()
This fixes the following warning of gcc (tested on OpenBSD 5.0:)
irc-info.c:990: warning: strcpy() is almost always misused,
please use strlcpy
This commit is contained in:
@@ -987,7 +987,7 @@ IRC_WHO_Mask(CLIENT *Client, char *Mask, bool OnlyOps)
|
||||
if (IRC_CheckListTooBig(Client, count, MAX_RPL_WHO, "WHO"))
|
||||
break;
|
||||
|
||||
strcpy(flags, who_flags_status(Client_Modes(c)));
|
||||
strlcpy(flags, who_flags_status(Client_Modes(c)), sizeof(flags));
|
||||
if (strchr(Client_Modes(c), 'o'))
|
||||
strlcat(flags, "*", sizeof(flags));
|
||||
|
||||
|
||||
Reference in New Issue
Block a user