forked from OSchip/llvm-project
[lldb] Fix break introduced in 14735ca
The `File::OpenOptions` were renamed; this fixes up a callsite that breaks for
macOS builds. (See
14735cab65
)
Differential Revision: https://reviews.llvm.org/D107767
This commit is contained in:
parent
eabae4cf57
commit
875a16bcfc
|
@ -425,10 +425,12 @@ static Status HandleFileAction(ProcessLaunchInfo &launch_info,
|
|||
open(file_spec.GetPath().c_str(), oflag, S_IRUSR | S_IWUSR);
|
||||
if (created_fd >= 0) {
|
||||
auto file_options = File::OpenOptions(0);
|
||||
if ((oflag & O_RDWR) || (oflag & O_RDONLY))
|
||||
file_options |= File::eOpenOptionRead;
|
||||
if ((oflag & O_RDWR) || (oflag & O_RDONLY))
|
||||
file_options |= File::eOpenOptionWrite;
|
||||
if (oflag & O_RDWR)
|
||||
file_options |= File::eOpenOptionReadWrite;
|
||||
else if (oflag & O_WRONLY)
|
||||
file_options |= File::eOpenOptionWriteOnly;
|
||||
else if (oflag & O_RDONLY)
|
||||
file_options |= File::eOpenOptionReadOnly;
|
||||
file = std::make_shared<NativeFile>(created_fd, file_options, true);
|
||||
[options setValue:[NSNumber numberWithInteger:created_fd] forKey:key];
|
||||
return error; // Success
|
||||
|
|
Loading…
Reference in New Issue