diff options
author | Ron Yorston <rmy@pobox.com> | 2014-08-16 20:02:47 +0100 |
---|---|---|
committer | Ron Yorston <rmy@pobox.com> | 2014-08-16 20:02:47 +0100 |
commit | 44be915e702e63af8440902058fc4ad6b3fb1b75 (patch) | |
tree | 6c67b0a8e62e0ebf7eedb59c204c9ab7a52a554b /win32 | |
parent | 04135487de57ac90ca4697f90a27279896513016 (diff) | |
download | busybox-w32-44be915e702e63af8440902058fc4ad6b3fb1b75.tar.gz busybox-w32-44be915e702e63af8440902058fc4ad6b3fb1b75.tar.bz2 busybox-w32-44be915e702e63af8440902058fc4ad6b3fb1b75.zip |
stat: give directories write and execute permissions
Microsoft Windows ignores the read-only attribute on directories and
has no equivalent to the Unix execute permission on directories.
Treat all directories as writable and searchable.
Diffstat (limited to 'win32')
-rw-r--r-- | win32/mingw.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/win32/mingw.c b/win32/mingw.c index 9f225e88f..f98aec44b 100644 --- a/win32/mingw.c +++ b/win32/mingw.c | |||
@@ -182,7 +182,7 @@ static inline int file_attr_to_st_mode (DWORD attr) | |||
182 | { | 182 | { |
183 | int fMode = S_IREAD; | 183 | int fMode = S_IREAD; |
184 | if (attr & FILE_ATTRIBUTE_DIRECTORY) | 184 | if (attr & FILE_ATTRIBUTE_DIRECTORY) |
185 | fMode |= S_IFDIR; | 185 | fMode |= S_IFDIR|S_IWRITE|S_IEXEC; |
186 | else | 186 | else |
187 | fMode |= S_IFREG; | 187 | fMode |= S_IFREG; |
188 | if (!(attr & FILE_ATTRIBUTE_READONLY)) | 188 | if (!(attr & FILE_ATTRIBUTE_READONLY)) |