Skip to content

Foundation.Process on Linux throws error Error Domain=NSCocoaErrorDomain Code=256 "(null)" if executable not found #4810

Open
@weissi

Description

@weissi

When creating a Process with executableURL set to a file that doesn't exist, it throws

Error Domain=NSCocoaErrorDomain Code=256 "(null)"

which corresponds to an NSError with domain: NSCocoaErrorDomain (correct) and code: NSFileReadUnknownError (== 256`, incorrect).

Darwin systems have the correct

Error Domain=NSCocoaErrorDomain Code=4 "The file “exist” doesn’t exist." UserInfo={NSFilePath=/dev/null/does/not/exist}

which is code: NSFileNoSuchFileError (== 4).

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions