Skip to content
This repository has been archived by the owner on Jun 28, 2023. It is now read-only.

Commit

Permalink
fshelp: fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
a1ive committed Feb 28, 2020
1 parent 08359b0 commit e50a9ef
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions grub-core/fs/fshelp.c
Original file line number Diff line number Diff line change
Expand Up @@ -425,9 +425,13 @@ grub_fshelp_read_file (grub_disk_t disk, grub_fshelp_node_t node,
return -1;
}
else
grub_memset (buf, 0, blockend);
{
if (buf)
grub_memset (buf, 0, blockend);
}

buf += blocksize - skipfirst;
if (buf)
buf += blocksize - skipfirst;
}

return len;
Expand Down

0 comments on commit e50a9ef

Please sign in to comment.