aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Interpreter/ScriptInterpreter.cpp
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2022-05-31 17:22:18 -0700
committerJim Ingham <jingham@apple.com>2022-05-31 17:24:14 -0700
commitd92f7f790c8e74bf796a0313cb296d726628142e (patch)
tree80e34ba949a750730a3f687c45fd45c7da2fd89f /lldb/source/Interpreter/ScriptInterpreter.cpp
parentca73de43744503a557b1f3709c0ff4751798702f (diff)
downloadllvm-d92f7f790c8e74bf796a0313cb296d726628142e.zip
llvm-d92f7f790c8e74bf796a0313cb296d726628142e.tar.gz
llvm-d92f7f790c8e74bf796a0313cb296d726628142e.tar.bz2
Fix a copy-paste error in "br com add -s py -o 'some_python' BKPT_NAME"
The function that was supposed to iterate over all the breakpoints sharing BKPT_NAME stopped after the first one because of a reversed "if success" condition. Differential Revision: https://reviews.llvm.org/D126730
Diffstat (limited to 'lldb/source/Interpreter/ScriptInterpreter.cpp')
-rw-r--r--lldb/source/Interpreter/ScriptInterpreter.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/lldb/source/Interpreter/ScriptInterpreter.cpp b/lldb/source/Interpreter/ScriptInterpreter.cpp
index fbdcbb8..bc8a542 100644
--- a/lldb/source/Interpreter/ScriptInterpreter.cpp
+++ b/lldb/source/Interpreter/ScriptInterpreter.cpp
@@ -109,13 +109,13 @@ ScriptInterpreter::StringToLanguage(const llvm::StringRef &language) {
Status ScriptInterpreter::SetBreakpointCommandCallback(
std::vector<std::reference_wrapper<BreakpointOptions>> &bp_options_vec,
const char *callback_text) {
- Status return_error;
+ Status error;
for (BreakpointOptions &bp_options : bp_options_vec) {
- return_error = SetBreakpointCommandCallback(bp_options, callback_text);
- if (return_error.Success())
+ error = SetBreakpointCommandCallback(bp_options, callback_text);
+ if (!error.Success())
break;
}
- return return_error;
+ return error;
}
Status ScriptInterpreter::SetBreakpointCommandCallbackFunction(