aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/API/SBThread.cpp
diff options
context:
space:
mode:
authorJonas Devlieghere <jonas@devlieghere.com>2020-02-05 21:20:12 -0800
committerJonas Devlieghere <jonas@devlieghere.com>2020-02-05 21:55:36 -0800
commit3da7dcf38a96b7ba8ba0cb61be40210ace3fd91f (patch)
tree8c35226c15011a4a2419602fd0edb15f2ae9437e /lldb/source/API/SBThread.cpp
parent8dc3da7d58fe253b17bbfbdb5b4b51e8f0aa2e0f (diff)
downloadllvm-3da7dcf38a96b7ba8ba0cb61be40210ace3fd91f.zip
llvm-3da7dcf38a96b7ba8ba0cb61be40210ace3fd91f.tar.gz
llvm-3da7dcf38a96b7ba8ba0cb61be40210ace3fd91f.tar.bz2
[lldb/Reproducers] Serialize empty string for char* methods.
For the methods taking a char* and a length that have a custom replayer, ignore the incoming string in the instrumentation macro. This prevents potentially reading garbage and blowing up the SB API log.
Diffstat (limited to 'lldb/source/API/SBThread.cpp')
-rw-r--r--lldb/source/API/SBThread.cpp17
1 files changed, 7 insertions, 10 deletions
diff --git a/lldb/source/API/SBThread.cpp b/lldb/source/API/SBThread.cpp
index ff1a428..69342b9 100644
--- a/lldb/source/API/SBThread.cpp
+++ b/lldb/source/API/SBThread.cpp
@@ -313,8 +313,8 @@ SBThread::GetStopReasonExtendedBacktraces(InstrumentationRuntimeType type) {
}
size_t SBThread::GetStopDescription(char *dst, size_t dst_len) {
- LLDB_RECORD_METHOD(size_t, SBThread, GetStopDescription, (char *, size_t),
- dst, dst_len);
+ LLDB_RECORD_METHOD(size_t, SBThread, GetStopDescription, (char *, size_t), "",
+ dst_len);
std::unique_lock<std::recursive_mutex> lock;
ExecutionContext exe_ctx(m_opaque_sp.get(), lock);
@@ -970,23 +970,20 @@ SBError SBThread::StepUsingScriptedThreadPlan(const char *script_class_name) {
SBError SBThread::StepUsingScriptedThreadPlan(const char *script_class_name,
bool resume_immediately) {
LLDB_RECORD_METHOD(lldb::SBError, SBThread, StepUsingScriptedThreadPlan,
- (const char *, bool), script_class_name,
+ (const char *, bool), script_class_name,
resume_immediately);
lldb::SBStructuredData no_data;
- return LLDB_RECORD_RESULT(
- StepUsingScriptedThreadPlan(script_class_name,
- no_data,
- resume_immediately));
+ return LLDB_RECORD_RESULT(StepUsingScriptedThreadPlan(
+ script_class_name, no_data, resume_immediately));
}
SBError SBThread::StepUsingScriptedThreadPlan(const char *script_class_name,
SBStructuredData &args_data,
bool resume_immediately) {
LLDB_RECORD_METHOD(lldb::SBError, SBThread, StepUsingScriptedThreadPlan,
- (const char *, lldb::SBStructuredData &, bool),
- script_class_name, args_data,
- resume_immediately);
+ (const char *, lldb::SBStructuredData &, bool),
+ script_class_name, args_data, resume_immediately);
SBError error;