[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:
Robin Giese 2021-08-09 17:16:12 +02:00 committed by Raphael Isemann
parent eabae4cf57
commit 875a16bcfc
1 changed files with 6 additions and 4 deletions

View File

@ -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