Fix crash when trying to select (view) threads when debuggee is running
This commit is contained in:
parent
c6186ce600
commit
430c80ff2a
1 changed files with 4 additions and 1 deletions
|
@ -43,7 +43,10 @@ pub async fn select_thread_id(editor: &mut Editor, thread_id: isize, force: bool
|
||||||
|
|
||||||
// fetch stack trace
|
// fetch stack trace
|
||||||
// TODO: handle requesting more total frames
|
// TODO: handle requesting more total frames
|
||||||
let (frames, _) = debugger.stack_trace(thread_id).await.unwrap();
|
let (frames, _) = match debugger.stack_trace(thread_id).await {
|
||||||
|
Ok(frames) => frames,
|
||||||
|
Err(_) => return,
|
||||||
|
};
|
||||||
debugger.stack_frames.insert(thread_id, frames);
|
debugger.stack_frames.insert(thread_id, frames);
|
||||||
debugger.active_frame = Some(0); // TODO: check how to determine this
|
debugger.active_frame = Some(0); // TODO: check how to determine this
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue