diff options
-rw-r--r-- | win32/mingw.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/win32/mingw.c b/win32/mingw.c index a8170bb9c..b1225665c 100644 --- a/win32/mingw.c +++ b/win32/mingw.c | |||
@@ -359,8 +359,9 @@ static int get_file_attr(const char *fname, WIN32_FILE_ATTRIBUTE_DATA *fdata) | |||
359 | { | 359 | { |
360 | char *want_dir; | 360 | char *want_dir; |
361 | 361 | ||
362 | if (get_dev_type(fname) != NOT_DEVICE || get_dev_fd(fname) >= 0) { | 362 | if (get_dev_type(fname) == DEV_NULL || get_dev_fd(fname) >= 0) { |
363 | /* Fake attributes for special devices */ | 363 | /* Fake attributes for special devices */ |
364 | /* Though not /dev/zero or /dev/urandom */ | ||
364 | FILETIME epoch = {0xd53e8000, 0x019db1de}; // Unix epoch as FILETIME | 365 | FILETIME epoch = {0xd53e8000, 0x019db1de}; // Unix epoch as FILETIME |
365 | fdata->dwFileAttributes = FILE_ATTRIBUTE_DEVICE; | 366 | fdata->dwFileAttributes = FILE_ATTRIBUTE_DEVICE; |
366 | fdata->ftCreationTime = fdata->ftLastAccessTime = | 367 | fdata->ftCreationTime = fdata->ftLastAccessTime = |