diff options
Diffstat (limited to 'src/processor/stackwalker_amd64.cc')
-rw-r--r-- | src/processor/stackwalker_amd64.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/processor/stackwalker_amd64.cc b/src/processor/stackwalker_amd64.cc index 1cf9132e..b2ffdb89 100644 --- a/src/processor/stackwalker_amd64.cc +++ b/src/processor/stackwalker_amd64.cc @@ -197,7 +197,8 @@ StackFrameAMD64* StackwalkerAMD64::GetCallerByStackScan( return frame; } -StackFrame* StackwalkerAMD64::GetCallerFrame(const CallStack* stack) { +StackFrame* StackwalkerAMD64::GetCallerFrame(const CallStack* stack, + bool stack_scan_allowed) { if (!memory_ || !stack) { BPLOG(ERROR) << "Can't get caller frame without memory or stack"; return NULL; @@ -215,7 +216,7 @@ StackFrame* StackwalkerAMD64::GetCallerFrame(const CallStack* stack) { // If CFI failed, or there wasn't CFI available, fall back // to stack scanning. - if (!new_frame.get()) { + if (stack_scan_allowed && !new_frame.get()) { new_frame.reset(GetCallerByStackScan(frames)); } |