Fixed the x86_64 setjmp implementation.

* typedef for jmp_buf was using int where it should be long.
* setjmp was clearing the buffer pointer rather than the signal mask before
  calling sigsetjmp.
* KDL now works without crashing on x86_64.
This commit is contained in:
Alex Smith 2012-07-05 13:52:36 +01:00
parent 78d482e3b8
commit 2f36ef5afe
2 changed files with 2 additions and 2 deletions

View File

@ -6,6 +6,6 @@
#define _ARCH_SETJMP_H_
typedef int __jmp_buf[8];
typedef unsigned long __jmp_buf[8];
#endif /* _ARCH_SETJMP_H_ */

View File

@ -31,7 +31,7 @@ FUNCTION_END(setjmp)
/* int setjmp(jmp_buf buffer) */
FUNCTION(setjmp):
// Jump to sigsetjmp with a zero saveMask.
xorl %edi, %edi
xorl %esi, %esi
jmp sigsetjmp
FUNCTION_END(setjmp)