From 36d5868898ecfc6337b7f6a5f49439c4106d9c67 Mon Sep 17 00:00:00 2001 From: Marcus Brinkmann Date: Wed, 31 Jul 2002 02:35:14 +0000 Subject: Add comment to last change, for the benefit of the next merge :) --- libthreads/cthreads.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'libthreads') diff --git a/libthreads/cthreads.c b/libthreads/cthreads.c index a68b7ee6..38c65665 100644 --- a/libthreads/cthreads.c +++ b/libthreads/cthreads.c @@ -30,6 +30,12 @@ * catch is reserved word in c++. * * $Log: cthreads.c,v $ + * Revision 1.14 2002/07/31 02:20:44 marcus + * 2002-07-29 Marcus Brinkmann + * + * * cthreads.c (cthread_init): Move cthread_alloc call before + * cproc_init call (lost in merge). + * * Revision 1.13 2002/05/28 23:55:55 roland * 2002-05-28 Roland McGrath * @@ -217,6 +223,10 @@ cthread_init(void) if (cthreads_started) return 0; + + /* cthread_alloc must be called before cproc_init, because + malloc is not usable between initializing the new stack and + switching to it. */ t = cthread_alloc((cthread_fn_t) 0, (any_t) 0); stack = cproc_init(); cthread_cprocs = 1; -- cgit v1.2.3