[Lldb-commits] [lldb] c4a83c4 - Fix TestVSCode_runInTerminal

Walter Erquinigo via lldb-commits lldb-commits at lists.llvm.org
Wed Apr 21 15:22:00 PDT 2021


Author: Walter Erquinigo
Date: 2021-04-21T15:20:47-07:00
New Revision: c4a83c4e69f1c858df787723df4923c41a23e00d

URL: https://github.com/llvm/llvm-project/commit/c4a83c4e69f1c858df787723df4923c41a23e00d
DIFF: https://github.com/llvm/llvm-project/commit/c4a83c4e69f1c858df787723df4923c41a23e00d.diff

LOG: Fix TestVSCode_runInTerminal

It failed in https://lab.llvm.org/buildbot/#/builders/68/builds/10912

And it was caused due to https://reviews.llvm.org/rG64f47c1e58a1

Added: 
    

Modified: 
    lldb/tools/lldb-vscode/lldb-vscode.cpp

Removed: 
    


################################################################################
diff  --git a/lldb/tools/lldb-vscode/lldb-vscode.cpp b/lldb/tools/lldb-vscode/lldb-vscode.cpp
index b810bf738526..95074bb1c984 100644
--- a/lldb/tools/lldb-vscode/lldb-vscode.cpp
+++ b/lldb/tools/lldb-vscode/lldb-vscode.cpp
@@ -3149,9 +3149,6 @@ int main(int argc, char *argv[]) {
   llvm::InitLLVM IL(argc, argv, /*InstallPipeSignalExitHandler=*/false);
   llvm::PrettyStackTraceProgram X(argc, argv);
 
-  // stdout/stderr redirection to the IDE's console
-  int new_stdout_fd = SetupStdoutStderrRedirection();
-
   llvm::SmallString<256> program_path(argv[0]);
   llvm::sys::fs::make_absolute(program_path);
   g_vsc.debug_adaptor_path = program_path.str().str();
@@ -3178,6 +3175,9 @@ int main(int argc, char *argv[]) {
     }
   }
 
+  // stdout/stderr redirection to the IDE's console
+  int new_stdout_fd = SetupStdoutStderrRedirection();
+
   // Initialize LLDB first before we do anything.
   lldb::SBDebugger::Initialize();
 


        


More information about the lldb-commits mailing list