X-Git-Url: http://nsz.repo.hu/git/?p=musl;a=blobdiff_plain;f=include%2Fucontext.h;h=1121761626b65c41977e51473991273abb0670fe;hp=96c27cb7acf6b78ab8bad16b0229bc7d9ab68d43;hb=43a5a00e4ab292e0a615b655f1e77837d6c1701e;hpb=798a12ecc4ec4a7780beaf2f5fb86ffbc9738755 diff --git a/include/ucontext.h b/include/ucontext.h index 96c27cb7..11217616 100644 --- a/include/ucontext.h +++ b/include/ucontext.h @@ -6,31 +6,16 @@ extern "C" { #include -struct __fpstate { - unsigned long __x[7]; - unsigned char __y[80]; - unsigned long __z; -}; - -typedef struct { - unsigned long __gregs[19]; - void *__fpregs; - unsigned long __oldmask, __cr2; -} mcontext_t; +#ifdef _GNU_SOURCE +#define ucontext __ucontext +#endif -typedef struct ucontext { - unsigned long uc_flags; - struct ucontext *uc_link; - stack_t uc_stack; - mcontext_t uc_mcontext; - sigset_t uc_sigmask; - struct __fpstate __fpregs_mem; -} ucontext_t; +struct __ucontext; -int getcontext(ucontext_t *); -void makecontext(ucontext_t *, void (*)(void), int, ...); -int setcontext(const ucontext_t *); -int swapcontext(ucontext_t *, const ucontext_t *); +int getcontext(struct __ucontext *); +void makecontext(struct __ucontext *, void (*)(void), int, ...); +int setcontext(const struct __ucontext *); +int swapcontext(struct __ucontext *, const struct __ucontext *); #ifdef __cplusplus }