]> git.ipfire.org Git - thirdparty/grub.git/commit
file: ignore host disk in blocklist check
authorAndrei Borzenkov <arvidjaar@gmail.com>
Sat, 10 Oct 2015 07:02:20 +0000 (10:02 +0300)
committerAndrei Borzenkov <arvidjaar@gmail.com>
Sat, 10 Oct 2015 07:02:20 +0000 (10:02 +0300)
commitd31321835e9e0b2e1c792b8834840eb148cdd29f
tree5a3e651a5cea12055120b4cb8fd3b6e5014cdb75
parentc2443e49bc2a165744dab596b4a9d1b04f52da83
file: ignore host disk in blocklist check

It cannot work anyway because host disk cannot be read. This fixes hostfs access
on native Windows build where filenames start with '\' or do not have initial
separator at all (d:\foo).

Issue was observed when running grub-fstest on Windows. On UNIX image name is
canonicalized to always start with `/' so this was not noticed.

This has side effect of allowing relative path names on host, but this already
was the case with `ls' command, so it just extends it to all commands.

Reported-By: Arch Stack <archstacker@gmail.com>
Also-By: Arch Stack <archstacker@gmail.com>
grub-core/kern/file.c