diff options
Diffstat (limited to 'lldb/source/Commands/CommandCompletions.cpp')
-rw-r--r-- | lldb/source/Commands/CommandCompletions.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lldb/source/Commands/CommandCompletions.cpp b/lldb/source/Commands/CommandCompletions.cpp index fd84e1c4f85..34cad970ff6 100644 --- a/lldb/source/Commands/CommandCompletions.cpp +++ b/lldb/source/Commands/CommandCompletions.cpp @@ -199,14 +199,14 @@ static int DiskFilesOrDirectories(const llvm::Twine &partial_name, // We have a match. - fs::file_status st; - if ((EC = Entry.status(st))) + llvm::ErrorOr<fs::basic_file_status> st = Entry.status(); + if (!st) continue; // If it's a symlink, then we treat it as a directory as long as the target // is a directory. - bool is_dir = fs::is_directory(st); - if (fs::is_symlink_file(st)) { + bool is_dir = fs::is_directory(*st); + if (fs::is_symlink_file(*st)) { fs::file_status target_st; if (!fs::status(Entry.path(), target_st)) is_dir = fs::is_directory(target_st); |