Bound the sizes of strcpy.
This commit is contained in:
parent
a3ffa2455b
commit
53cb12b4d0
2 changed files with 2 additions and 2 deletions
|
@ -1114,7 +1114,7 @@ static int say(struct command_t *command)
|
|||
{
|
||||
if (command->wd2 > 0) {
|
||||
command->wd1 = command->wd2;
|
||||
strcpy(command->raw1, command->raw2);
|
||||
strncpy(command->raw1, command->raw2, LINESIZE - 1);
|
||||
}
|
||||
char word1[TOKLEN + 1];
|
||||
packed_to_token(command->wd1, word1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue