summaryrefslogtreecommitdiffstats
path: root/lib/libc/gen/pause.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/gen/pause.c')
-rw-r--r--lib/libc/gen/pause.c18
1 files changed, 15 insertions, 3 deletions
diff --git a/lib/libc/gen/pause.c b/lib/libc/gen/pause.c
index 51706cf..97fbb01 100644
--- a/lib/libc/gen/pause.c
+++ b/lib/libc/gen/pause.c
@@ -38,11 +38,13 @@ __FBSDID("$FreeBSD$");
#include <unistd.h>
#include "un-namespace.h"
+#include "libc_private.h"
+
/*
* Backwards compatible pause.
*/
int
-__pause(void)
+__libc_pause(void)
{
sigset_t oset;
@@ -50,5 +52,15 @@ __pause(void)
return (-1);
return (_sigsuspend(&oset));
}
-__weak_reference(__pause, pause);
-__weak_reference(__pause, _pause);
+
+#pragma weak pause
+int
+pause(void)
+{
+
+ return (((int (*)(void))
+ __libc_interposing[INTERPOS_pause])());
+}
+
+__weak_reference(__libc_pause, __pause);
+__weak_reference(__libc_pause, _pause);
OpenPOWER on IntegriCloud