* grub-core/normal/menu_entry.c (run): Use grub_memcpy rather than
grub_strcpy since the lines aren't necessarily 0-terminated.
This commit is contained in:
parent
7c2e4909c3
commit
d7a565e962
2 changed files with 6 additions and 1 deletions
|
@ -1185,7 +1185,7 @@ run (struct screen *screen)
|
|||
size = 0;
|
||||
for (i = 0; i < screen->num_lines; i++)
|
||||
{
|
||||
grub_strcpy (source + size, screen->lines[i].buf);
|
||||
grub_memcpy (source + size, screen->lines[i].buf, screen->lines[i].len);
|
||||
size += screen->lines[i].len;
|
||||
source[size++] = '\n';
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue