diff --git a/proc/stack.go b/proc/stack.go index aa4e6585..bd3e633f 100644 --- a/proc/stack.go +++ b/proc/stack.go @@ -127,6 +127,9 @@ func (it *stackIterator) Next() bool { } if it.frame.Current.Fn == nil { + if it.top { + it.err = fmt.Errorf("PC not associated to any function") + } return false }