diff options
Diffstat (limited to 'sysdeps/powerpc/powerpc64/backtrace.c')
-rw-r--r-- | sysdeps/powerpc/powerpc64/backtrace.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sysdeps/powerpc/powerpc64/backtrace.c b/sysdeps/powerpc/powerpc64/backtrace.c index 919bf1c..dd25b90 100644 --- a/sysdeps/powerpc/powerpc64/backtrace.c +++ b/sysdeps/powerpc/powerpc64/backtrace.c @@ -87,6 +87,8 @@ __backtrace (void **array, int size) if (is_sigtramp_address (current->return_address)) { struct signal_frame_64 *sigframe = (struct signal_frame_64*) current; + if (count + 1 == size) + break; array[++count] = (void*) sigframe->uc.uc_mcontext.gp_regs[PT_NIP]; current = (void*) sigframe->uc.uc_mcontext.gp_regs[PT_R1]; } |