diff options
author | Walter Erquinigo <wallace@fb.com> | 2022-06-28 17:38:17 -0700 |
---|---|---|
committer | Walter Erquinigo <wallace@fb.com> | 2022-06-28 17:54:30 -0700 |
commit | 6564ca188a122c79c36ad7e4b3d362fb22fbd0b5 (patch) | |
tree | 276a109fb23e1484343282d119f9aeba27d711da /lldb/source/Commands/CommandObjectThread.cpp | |
parent | 5dcc5254925ad84b3949b2bef8345579611bd6f9 (diff) | |
download | llvm-6564ca188a122c79c36ad7e4b3d362fb22fbd0b5.zip llvm-6564ca188a122c79c36ad7e4b3d362fb22fbd0b5.tar.gz llvm-6564ca188a122c79c36ad7e4b3d362fb22fbd0b5.tar.bz2 |
[trace] Fix errors when handling command arguments
https://reviews.llvm.org/D128453 recently added some safety checks for
command arguments. Unfortunately, some few commands started failing due
to that, and this diff fixes it. But fortunately, the fix is trivial, which is
simply declaring the argument that these commands will receive.
Differential Revision: https://reviews.llvm.org/D128775
Diffstat (limited to 'lldb/source/Commands/CommandObjectThread.cpp')
-rw-r--r-- | lldb/source/Commands/CommandObjectThread.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lldb/source/Commands/CommandObjectThread.cpp b/lldb/source/Commands/CommandObjectThread.cpp index 65512a05..7dd89e6 100644 --- a/lldb/source/Commands/CommandObjectThread.cpp +++ b/lldb/source/Commands/CommandObjectThread.cpp @@ -2219,7 +2219,10 @@ public: nullptr, eCommandRequiresProcess | eCommandRequiresThread | eCommandTryTargetAPILock | eCommandProcessMustBeLaunched | - eCommandProcessMustBePaused | eCommandProcessMustBeTraced) {} + eCommandProcessMustBePaused | eCommandProcessMustBeTraced) { + CommandArgumentData thread_arg{eArgTypeThreadIndex, eArgRepeatOptional}; + m_arguments.push_back({thread_arg}); + } ~CommandObjectTraceDumpInstructions() override = default; |