2009-09-02 Colin Watson <cjwatson@ubuntu.com>

* util/grub-probe.c (probe): Test st.st_mode using S_ISREG macro
	rather than comparing against S_IFREG, which will almost never work.
This commit is contained in:
cjwatson 2009-09-02 01:42:06 +00:00
parent aa0f752dfe
commit c0bc232b72
2 changed files with 6 additions and 1 deletions

View file

@ -239,7 +239,7 @@ probe (const char *path, char *device_name)
stat (path, &st);
if (st.st_mode == S_IFREG)
if (S_ISREG (st.st_mode))
{
/* Regular file. Verify that we can read it properly. */