Hello,
On my linux 2.6.24 x86_64 kernel with x86 userland the is_signal_frame
function is not working for SA_SIGINFO signals (always returns 0). This is
because after the sigreturn syscall there is a 00-byte instead of a
nop-instruction as the code expects.
The attached patch fixes this problem (and corrects a comment typo).
Arne
--- src/x86/Gis_signal_frame.c 2010-04-03 16:12:18.000000000 +0200
+++ ../libunwind-0.99/src/x86/Gis_signal_frame.c 2010-04-02
11:50:42.000000000 +0200
@@ -50,9 +50,8 @@
without SA_SIGINFO, and
__restore_rt:
- 0xb8 0xad 0x00 0x00 0x00 movl 0x80,%eax
+ 0xb8 0xad 0x00 0x00 0x00 movl 0xad,%eax
0xcd 0x80 int 0x80
- 0x90 nop
if SA_SIGINFO is specified.
*/
@@ -61,7 +60,7 @@
|| (ret = (*a->access_mem) (as, ip + 4, &w1, 0, arg)) < 0)
return ret;
ret = ((w0 == 0x0077b858 && w1 == 0x80cd0000)
- || (w0 == 0x0000adb8 && w1 == 0x9080cd00));
+ || (w0 == 0x0000adb8 && (w1 & 0xffffff) == 0x80cd00));
Debug (16, "returning %d\n", ret);
return ret;
#else
_______________________________________________
Libunwind-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/libunwind-devel