We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents ae46e13 + ef302c8 commit c5597baCopy full SHA for c5597ba
1 file changed
compat/mingw.c
@@ -1012,8 +1012,8 @@ static int has_valid_directory_prefix(wchar_t *wfilename)
1012
wfilename[n] = L'\0';
1013
attributes = GetFileAttributesW(wfilename);
1014
wfilename[n] = c;
1015
- if (attributes == FILE_ATTRIBUTE_DIRECTORY ||
1016
- attributes == FILE_ATTRIBUTE_DEVICE)
+ if (attributes &
+ (FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_DEVICE))
1017
return 1;
1018
if (attributes == INVALID_FILE_ATTRIBUTES)
1019
switch (GetLastError()) {
0 commit comments