Skip to content

Commit 4ec9cda

Browse files
committed
[lldb/test] Fix failures following ec456ba
This patch fixes the various crashlog test failures following ec456ba, which renamed the process member variable in the Scripted Thread python base class. This patch updates the crashlog scripted process implementation to reflect that change. Signed-off-by: Med Ismail Bennani <[email protected]>
1 parent 6ca5b81 commit 4ec9cda

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

lldb/examples/python/crashlog_scripted_process.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -159,14 +159,14 @@ def resolve_stackframes(thread, addr_mask, target):
159159
return frames
160160

161161
def create_stackframes(self):
162-
if not (self.scripted_process.load_all_images or self.has_crashed):
162+
if not (self.originating_process.load_all_images or self.has_crashed):
163163
return None
164164

165165
if not self.backing_thread or not len(self.backing_thread.frames):
166166
return None
167167

168168
self.frames = CrashLogScriptedThread.resolve_stackframes(
169-
self.backing_thread, self.scripted_process.addr_mask, self.target
169+
self.backing_thread, self.originating_process.addr_mask, self.target
170170
)
171171

172172
return self.frames
@@ -182,7 +182,7 @@ def __init__(self, process, args, crashlog_thread):
182182
else:
183183
self.name = self.backing_thread.name
184184
self.queue = self.backing_thread.queue
185-
self.has_crashed = self.scripted_process.crashed_thread_idx == self.idx
185+
self.has_crashed = self.originating_process.crashed_thread_idx == self.idx
186186
self.create_stackframes()
187187

188188
def get_state(self):
@@ -195,8 +195,8 @@ def get_stop_reason(self) -> Dict[str, Any]:
195195
return {"type": lldb.eStopReasonNone}
196196
# TODO: Investigate what stop reason should be reported when crashed
197197
stop_reason = {"type": lldb.eStopReasonException, "data": {}}
198-
if self.scripted_process.exception:
199-
stop_reason["data"]["mach_exception"] = self.scripted_process.exception
198+
if self.originating_process.exception:
199+
stop_reason["data"]["mach_exception"] = self.originating_process.exception
200200
return stop_reason
201201

202202
def get_register_context(self) -> str:
@@ -209,5 +209,5 @@ def get_register_context(self) -> str:
209209

210210
def get_extended_info(self):
211211
if self.has_crashed:
212-
self.extended_info = self.scripted_process.extended_thread_info
212+
self.extended_info = self.originating_process.extended_thread_info
213213
return self.extended_info

0 commit comments

Comments
 (0)