Skip to content
This repository has been archived by the owner on Jan 30, 2024. It is now read-only.

Commit

Permalink
Merge pull request #402 from knurling-rs/fix-401
Browse files Browse the repository at this point in the history
Do not panic if locations do not contain the frame
  • Loading branch information
Urhengulas authored May 15, 2023
2 parents da5da03 + 03f0f4b commit fa8f3ce
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,10 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/) and this p
## [Unreleased]

- [#404] Switch from bors to merge queue
- [#402] Do not panic if locations do not contain the frame

[#404]: https://github.com/knurling-rs/probe-run/pull/404
[#402]: https://github.com/knurling-rs/probe-run/pull/402

## [v0.3.9] - 2023-05-05

Expand Down
2 changes: 1 addition & 1 deletion src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ fn location_info(
shorten_paths: bool,
) -> (Option<String>, Option<u32>, Option<String>) {
locations
.map(|locations| &locations[&frame.index()])
.and_then(|locations| locations.get(&frame.index()))
.map(|location| {
let path = if let Ok(relpath) = location.file.strip_prefix(current_dir) {
relpath.display().to_string()
Expand Down

0 comments on commit fa8f3ce

Please sign in to comment.