[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Libunwind-devel] [PATCH 1/2] ARM: Exit unw_step in case DWARF based unw
From: |
Ken Werner |
Subject: |
[Libunwind-devel] [PATCH 1/2] ARM: Exit unw_step in case DWARF based unwinding was successful |
Date: |
Mon, 29 Aug 2011 18:19:43 +0200 |
Prevents unw_step from trying to unwind the stack using the ARM specific
unwind tables in case the DWARF based unwinding was successful.
Signed-off-by: Ken Werner <address@hidden>
---
src/arm/Gstep.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/arm/Gstep.c b/src/arm/Gstep.c
index 1dae78e..149a65a 100644
--- a/src/arm/Gstep.c
+++ b/src/arm/Gstep.c
@@ -177,8 +177,10 @@ unw_step (unw_cursor_t *cursor)
ret = dwarf_step (&c->dwarf);
Debug(1, "dwarf_step()=%d\n", ret);
- if (unlikely (ret == -UNW_ESTOPUNWIND))
- return ret;
+ if (likely (ret > 0))
+ return 1;
+ else if (unlikely (ret == -UNW_ESTOPUNWIND))
+ return ret;
if (ret < 0 && ret != -UNW_ENOINFO)
{
--
1.7.4.1