summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Xu <davidxu@FreeBSD.org>2004-07-13 22:51:03 +0000
committerDavid Xu <davidxu@FreeBSD.org>2004-07-13 22:51:03 +0000
commit099e4630c108c7c31797f1c2800801ac7fdf777c (patch)
treeb53af6ef6b69febaaea79d98c447977d02a94e11
parent566382df0ad602942b46c4de0161beee34bb5098 (diff)
Notes
-rw-r--r--lib/libkse/thread/thr_init.c6
-rw-r--r--lib/libpthread/thread/thr_init.c6
2 files changed, 12 insertions, 0 deletions
diff --git a/lib/libkse/thread/thr_init.c b/lib/libkse/thread/thr_init.c
index d7c6296d1115f..36e7e69c4712c 100644
--- a/lib/libkse/thread/thr_init.c
+++ b/lib/libkse/thread/thr_init.c
@@ -310,6 +310,12 @@ _libpthread_init(struct pthread *curthread)
_thr_signal_init();
_kse_critical_leave(&_thr_initial->tcb->tcb_tmbx);
+ /*
+ * activate threaded mode as soon as possible if we are
+ * being debugged
+ */
+ if (_libkse_debug)
+ _kse_setthreaded(1);
}
/*
diff --git a/lib/libpthread/thread/thr_init.c b/lib/libpthread/thread/thr_init.c
index d7c6296d1115f..36e7e69c4712c 100644
--- a/lib/libpthread/thread/thr_init.c
+++ b/lib/libpthread/thread/thr_init.c
@@ -310,6 +310,12 @@ _libpthread_init(struct pthread *curthread)
_thr_signal_init();
_kse_critical_leave(&_thr_initial->tcb->tcb_tmbx);
+ /*
+ * activate threaded mode as soon as possible if we are
+ * being debugged
+ */
+ if (_libkse_debug)
+ _kse_setthreaded(1);
}
/*