forked from lix-project/lix
Merge pull request #1545 from trofi/glibc-2.26
src/libmain/stack.cc: fix 'ucontext' usage on glibc-2.26
This commit is contained in:
commit
fe38fce2d8
1 changed files with 2 additions and 2 deletions
|
@ -18,9 +18,9 @@ static void sigsegvHandler(int signo, siginfo_t * info, void * ctx)
|
||||||
bool haveSP = true;
|
bool haveSP = true;
|
||||||
char * sp = 0;
|
char * sp = 0;
|
||||||
#if defined(__x86_64__) && defined(REG_RSP)
|
#if defined(__x86_64__) && defined(REG_RSP)
|
||||||
sp = (char *) ((ucontext *) ctx)->uc_mcontext.gregs[REG_RSP];
|
sp = (char *) ((ucontext_t *) ctx)->uc_mcontext.gregs[REG_RSP];
|
||||||
#elif defined(REG_ESP)
|
#elif defined(REG_ESP)
|
||||||
sp = (char *) ((ucontext *) ctx)->uc_mcontext.gregs[REG_ESP];
|
sp = (char *) ((ucontext_t *) ctx)->uc_mcontext.gregs[REG_ESP];
|
||||||
#else
|
#else
|
||||||
haveSP = false;
|
haveSP = false;
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue