From d28faf45be05bed11d5dbd509470a4449f5d1714 Mon Sep 17 00:00:00 2001 From: jasone Date: Thu, 20 Jan 2000 21:53:59 +0000 Subject: Minor *jmp() cleanups. --- lib/libc_r/uthread/pthread_private.h | 5 +++-- lib/libc_r/uthread/uthread_jmp.c | 16 +++++----------- 2 files changed, 8 insertions(+), 13 deletions(-) (limited to 'lib/libc_r') diff --git a/lib/libc_r/uthread/pthread_private.h b/lib/libc_r/uthread/pthread_private.h index 00ca3b0..962eb86 100644 --- a/lib/libc_r/uthread/pthread_private.h +++ b/lib/libc_r/uthread/pthread_private.h @@ -1245,8 +1245,9 @@ int _thread_sys_msync(void *, size_t, int); /* #include */ #ifdef _SETJMP_H_ -extern void __longjmp(jmp_buf, int); -extern void __siglongjmp(sigjmp_buf, int); +extern void __siglongjmp(sigjmp_buf, int) __dead2; +extern void __longjmp(jmp_buf, int) __dead2; +extern void ___longjmp(jmp_buf, int) __dead2; #endif __END_DECLS diff --git a/lib/libc_r/uthread/uthread_jmp.c b/lib/libc_r/uthread/uthread_jmp.c index 4be77cf..e81bcc1 100644 --- a/lib/libc_r/uthread/uthread_jmp.c +++ b/lib/libc_r/uthread/uthread_jmp.c @@ -54,7 +54,7 @@ #endif void -_libc_siglongjmp(sigjmp_buf env, int savemask) +siglongjmp(sigjmp_buf env, int savemask) { void *jmp_stackp; void *stack_begin, *stack_end; @@ -81,7 +81,7 @@ _libc_siglongjmp(sigjmp_buf env, int savemask) */ if (((jmp_stackp < stack_begin) && (jmp_stackp < stack_end)) || ((jmp_stackp > stack_begin) && (jmp_stackp > stack_end))) - PANIC("longjmp()ing between thread contexts is undefined by " + PANIC("siglongjmp()ing between thread contexts is undefined by " "POSIX 1003.1"); memcpy(_thread_run->nested_jmp.sigjmp, env, @@ -99,10 +99,8 @@ _libc_siglongjmp(sigjmp_buf env, int savemask) ___longjmp(*_thread_run->sighandler_jmp_buf, 1); } -__weak_reference(_libc_siglongjmp, siglongjmp); - void -_libc_longjmp(jmp_buf env, int val) +longjmp(jmp_buf env, int val) { void *jmp_stackp; void *stack_begin, *stack_end; @@ -147,10 +145,8 @@ _libc_longjmp(jmp_buf env, int val) ___longjmp(*_thread_run->sighandler_jmp_buf, 1); } -__weak_reference(_libc_longjmp, longjmp); - void -_libc__longjmp(jmp_buf env, int val) +_longjmp(jmp_buf env, int val) { void *jmp_stackp; void *stack_begin, *stack_end; @@ -177,7 +173,7 @@ _libc__longjmp(jmp_buf env, int val) */ if (((jmp_stackp < stack_begin) && (jmp_stackp < stack_end)) || ((jmp_stackp > stack_begin) && (jmp_stackp > stack_end))) - PANIC("longjmp()ing between thread contexts is undefined by " + PANIC("_longjmp()ing between thread contexts is undefined by " "POSIX 1003.1"); memcpy(_thread_run->nested_jmp.jmp, env, @@ -194,6 +190,4 @@ _libc__longjmp(jmp_buf env, int val) _thread_run->longjmp_val = val; ___longjmp(*_thread_run->sighandler_jmp_buf, 1); } - -__weak_reference(_libc__longjmp, _longjmp); #endif -- cgit v1.1