diff options
author | hboehm <hboehm> | 2007-07-02 17:17:46 +0000 |
---|---|---|
committer | Ivan Maidanski <ivmai@mail.ru> | 2011-07-26 21:06:41 +0400 |
commit | f165469dd058eea45b2615399f51979be7237bed (patch) | |
tree | 3303a53c6bdf4c0b816aa31be11b8f49747e2343 /mach_dep.c | |
parent | ff97a96866512f7f642a0c3addc4ba2b36b3ee12 (diff) | |
download | bdwgc-f165469dd058eea45b2615399f51979be7237bed.tar.gz |
2007-07-02 Hans Boehm <Hans.Boehm@hp.com>
* mach_dep.c (GC_with_callee_saves_pushed): Don't use getcontext()
on ARM/Linux. Check getcontext() return value.
Diffstat (limited to 'mach_dep.c')
-rw-r--r-- | mach_dep.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -174,10 +174,12 @@ void GC_with_callee_saves_pushed(void (*fn)(ptr_t, void *), # if defined(HAVE_PUSH_REGS) GC_push_regs(); -# elif defined(UNIX_LIKE) && !defined(DARWIN) +# elif defined(UNIX_LIKE) && !defined(DARWIN) && !defined(ARM32) /* Older versions of Darwin seem to lack getcontext(). */ + /* ARM Linux often doesn't support a real getcontext(). */ ucontext_t ctxt; - getcontext(&ctxt); + if (getcontext(&ctxt) < 0) + ABORT ("Getcontext failed: Use another register retrieval method?"); context = &ctxt; # if defined(SPARC) || defined(IA64) /* On a register window machine, we need to save register */ |