tatyana-krasnukha added a comment.

Added inline comment



================
Comment at: lldb/source/Interpreter/CommandInterpreter.cpp:2842
 
-  OverrideExecutionContext(m_debugger.GetSelectedExecutionContext());
-  auto finalize = llvm::make_scope_exit([this]() {
-    RestoreExecutionContext();
+  ExecutionContext exe_ctx = m_debugger.GetSelectedExecutionContext();
+  bool pushed_exe_ctx = false;
----------------
The intention of overriding the context here with the currently selected one 
was to have the same context during `HandleCommand` and `GetProcessOutput`. 
However, this logic looks wrong to me now. `HandleCommand` may change the 
context and `GetProcessOutput` should use the new one. I think that you can 
safely remove this piece of code (untill `IOHandlerInputComplete` doesn't allow 
overriding execution context).


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D111209/new/

https://reviews.llvm.org/D111209

_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to