From e1e4d6b269dd5c03480d55b031f2932df0490c96 Mon Sep 17 00:00:00 2001 From: Rich Felker Date: Thu, 12 Jul 2012 21:49:30 -0400 Subject: mipsel (little endian) support the fields in the mcontext_t are long long (for no good reason) even on 32-bit mips, so the offset of the instruction pointer (as a word) varies depending on endianness. --- arch/mips/pthread_arch.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch') diff --git a/arch/mips/pthread_arch.h b/arch/mips/pthread_arch.h index 60296fd6..f75379cf 100644 --- a/arch/mips/pthread_arch.h +++ b/arch/mips/pthread_arch.h @@ -5,4 +5,4 @@ static inline struct pthread *__pthread_self() return self; } -#define CANCEL_REG_IP 3 +#define CANCEL_REG_IP (3-(union {int __i; char __b;}){1}.__b) -- cgit v1.2.3-70-g09d2