We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents a132f6e + ad2cf4e commit 67e375fCopy full SHA for 67e375f
Foundation/FileManager.swift
@@ -857,9 +857,9 @@ open class FileManager : NSObject {
857
var faAttributes: WIN32_FILE_ATTRIBUTE_DATA = WIN32_FILE_ATTRIBUTE_DATA()
858
return try path.withCString(encodedAs: UTF16.self) {
859
if GetFileAttributesExW($0, GetFileExInfoStandard, &faAttributes) == FALSE {
860
- return faAttributes
+ throw _NSErrorWithWindowsError(GetLastError(), reading: true)
861
}
862
- throw _NSErrorWithWindowsError(GetLastError(), reading: true)
+ return faAttributes
863
864
865
#endif
0 commit comments