* grub-core/fs/bfs.c (mount): Improve filesystem detection reliability.
* grub-core/fs/ext2.c (grub_ext2_mount): Likewise. * grub-core/fs/hfs.c (grub_hfs_mount): Likewise. * grub-core/fs/hfsplus.c (grub_hfsplus_mount): Likewise. * grub-core/fs/jfs.c (grub_jfs_mount): Likewise. * grub-core/fs/minix.c (grub_minix_mount): Likewise. * grub-core/fs/ntfs.c (grub_ntfs_mount): Likewise. * grub-core/fs/romfs.c (grub_romfs_mount): Likewise. * grub-core/fs/xfs.c (grub_xfs_mount): Likewise.
This commit is contained in:
parent
fe8c2f1117
commit
2e57f28fc7
10 changed files with 63 additions and 18 deletions
|
@ -663,7 +663,10 @@ grub_xfs_mount (grub_disk_t disk)
|
|||
sizeof (struct grub_xfs_sblock), &data->sblock))
|
||||
goto fail;
|
||||
|
||||
if (grub_strncmp ((char *) (data->sblock.magic), "XFSB", 4))
|
||||
if (grub_strncmp ((char *) (data->sblock.magic), "XFSB", 4)
|
||||
|| data->sblock.log2_bsize < GRUB_DISK_SECTOR_BITS
|
||||
|| ((int) data->sblock.log2_bsize
|
||||
+ (int) data->sblock.log2_dirblk) >= 27)
|
||||
{
|
||||
grub_error (GRUB_ERR_BAD_FS, "not a XFS filesystem");
|
||||
goto fail;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue