From e768b77068a0b030a07576852bd0f121c9a077eb Mon Sep 17 00:00:00 2001 From: phcoder Date: Sat, 1 Aug 2009 14:44:15 +0000 Subject: [PATCH] --- ChangeLog | 5 +++++ util/hostfs.c | 6 ------ 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index 76e8c680c..f104a7c49 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-07-23 Vladimir Serbinenko + + * util/hostfs.c (grub_hostfs_dir): Don't use DT_DIR: It doesn't work + on XFS or ReiserFS. + 2009-08-01 Vladimir Serbinenko Support Apple partition map with sector size different from 512 bytes. diff --git a/util/hostfs.c b/util/hostfs.c index 1b963bb67..83db2f1a9 100644 --- a/util/hostfs.c +++ b/util/hostfs.c @@ -28,7 +28,6 @@ #include -#ifndef DT_DIR /* dirent.d_type is a BSD extension, not part of POSIX */ #include #include @@ -53,7 +52,6 @@ is_dir (const char *path, const char *name) return 0; return S_ISDIR (st.st_mode); } -#endif static grub_err_t grub_hostfs_dir (grub_device_t device, const char *path, @@ -81,11 +79,7 @@ grub_hostfs_dir (grub_device_t device, const char *path, if (! de) break; -#ifdef DT_DIR - info.dir = (de->d_type == DT_DIR); -#else info.dir = !! is_dir (path, de->d_name); -#endif hook (de->d_name, &info); }