You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apr.apache.org by rb...@apache.org on 2001/09/02 05:44:37 UTC
cvs commit: apr/threadproc/unix thread.c
rbb 01/09/01 20:44:37
Modified: threadproc/unix thread.c
Log:
Fix a seg-fault on Unix. It helps to allocate the structure before
we try to use it.
Revision Changes Path
1.48 +1 -0 apr/threadproc/unix/thread.c
Index: thread.c
===================================================================
RCS file: /home/cvs/apr/threadproc/unix/thread.c,v
retrieving revision 1.47
retrieving revision 1.48
diff -u -r1.47 -r1.48
--- thread.c 2001/08/27 10:48:05 1.47
+++ thread.c 2001/09/02 03:44:37 1.48
@@ -260,6 +260,7 @@
{
static const pthread_once_t once_init = PTHREAD_ONCE_INIT;
+ *control = apr_palloc(p, sizeof(**control));
(*control)->once = once_init;
return APR_SUCCESS;
}