Bug #937
- Fixed problem with incomplete 'stat' path. Signed-off-by: Paul Beckingham <paul@beckingham.net>
This commit is contained in:
committed by
Paul Beckingham
parent
8e5afa0d8a
commit
3ba0b62783
@@ -107,7 +107,7 @@ bool Directory::remove_directory (const std::string& dir)
|
||||
|
||||
#if defined (SOLARIS) || defined (HAIKU)
|
||||
struct stat s;
|
||||
stat (de->d_name, &s);
|
||||
stat ((dir + "/" + de->d_name).c_str (), &s);
|
||||
if (s.st_mode & S_IFDIR)
|
||||
remove_directory (dir + "/" + de->d_name);
|
||||
else
|
||||
@@ -160,7 +160,7 @@ void Directory::list (
|
||||
|
||||
#if defined (SOLARIS) || defined (HAIKU)
|
||||
struct stat s;
|
||||
stat (de->d_name, &s);
|
||||
stat ((base + "/" + de->d_name).c_str (), &s);
|
||||
if (recursive && s.st_mode & S_IFDIR)
|
||||
list (base + "/" + de->d_name, results, recursive);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user