Changeset View
Changeset View
Standalone View
Standalone View
lib/libc/sys/swapcontext.c
Show All 37 Lines | |||||
#include <stddef.h> | #include <stddef.h> | ||||
#include "libc_private.h" | #include "libc_private.h" | ||||
__weak_reference(__sys_swapcontext, __swapcontext); | __weak_reference(__sys_swapcontext, __swapcontext); | ||||
__sym_compat(swapcontext, __impl_swapcontext, FBSD_1.0); | __sym_compat(swapcontext, __impl_swapcontext, FBSD_1.0); | ||||
__weak_reference(swapcontext, __impl_swapcontext); | __weak_reference(swapcontext, __impl_swapcontext); | ||||
__sym_default(swapcontext, swapcontext, FBSD_1.2); | __sym_default(swapcontext, swapcontext, FBSD_1.2); | ||||
#pragma weak swapcontext | |||||
int | int | ||||
swapcontext(ucontext_t *oucp, const ucontext_t *ucp) | swapcontext(ucontext_t *oucp, const ucontext_t *ucp) | ||||
{ | { | ||||
return (((int (*)(ucontext_t *, const ucontext_t *)) | return (((int (*)(ucontext_t *, const ucontext_t *)) | ||||
__libc_interposing[INTERPOS_swapcontext])(oucp, ucp)); | __libc_interposing[INTERPOS_swapcontext])(oucp, ucp)); | ||||
} | } |