Skip to content

Commit

Permalink
fix crash on empty profile (#213)
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaqz authored Apr 2, 2023
1 parent 695449e commit 0f8565c
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/ProfileView.jl
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,12 @@ function viewprof_func(fcolor, c, g, fontsize, tb_items, graphtype)
Y = size(tagimg, 2)
x = max(1, min(x, size(tagimg, 1)))
y = max(1, min(y, Y))
tagimg[x,Y-y+1]
I = x, Y-y+1
if checkbounds(Bool, tagimg, I...)
tagimg[I...]
else
StackTraces.UNKNOWN
end
end
function device_bb(c)
if graphtype == :icicle
Expand Down

0 comments on commit 0f8565c

Please sign in to comment.