x86_64: add static assert verifying memory layout
parent
78e880a29f
commit
638770cfd0
|
@ -1,3 +1,5 @@
|
||||||
|
#include <stddef.h>
|
||||||
|
|
||||||
#ifndef LIBUCONTEXT_BITS_H
|
#ifndef LIBUCONTEXT_BITS_H
|
||||||
#define LIBUCONTEXT_BITS_H
|
#define LIBUCONTEXT_BITS_H
|
||||||
|
|
||||||
|
|
|
@ -20,6 +20,7 @@
|
||||||
|
|
||||||
extern void libucontext_trampoline(void);
|
extern void libucontext_trampoline(void);
|
||||||
|
|
||||||
|
_Static_assert(offsetof(libucontext_ucontext_t, uc_mcontext.gregs) == MCONTEXT_GREGS, "MCONTEXT_GREGS is invalid");
|
||||||
|
|
||||||
void
|
void
|
||||||
libucontext_makecontext(libucontext_ucontext_t *ucp, void (*func)(void), int argc, ...)
|
libucontext_makecontext(libucontext_ucontext_t *ucp, void (*func)(void), int argc, ...)
|
||||||
|
|
Loading…
Reference in New Issue