summaryrefslogtreecommitdiffstats
path: root/lib/libkse/thread/thr_single_np.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libkse/thread/thr_single_np.c')
-rw-r--r--lib/libkse/thread/thr_single_np.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/lib/libkse/thread/thr_single_np.c b/lib/libkse/thread/thr_single_np.c
index 85471b8..1ee5e79 100644
--- a/lib/libkse/thread/thr_single_np.c
+++ b/lib/libkse/thread/thr_single_np.c
@@ -31,17 +31,19 @@
*
* $FreeBSD$
*/
-#include <string.h>
#include <pthread.h>
-#include "pthread_private.h"
+#include <pthread_np.h>
__weak_reference(_pthread_single_np, pthread_single_np);
int _pthread_single_np()
{
- struct pthread *curthread = _get_curthread();
/* Enter single-threaded (non-POSIX) scheduling mode: */
- _thread_single = curthread;
- return(0);
+ pthread_suspend_all_np();
+ /*
+ * XXX - Do we want to do this?
+ * __is_threaded = 0;
+ */
+ return (0);
}
OpenPOWER on IntegriCloud