win32: Fix spurious apr_thread_once() failures.
* threadproc/win32/thread.c
(apr_thread_once): Pass NULL as lpContext argument in call to
InitOnceExecuteOnce(). According to documentation pointer stored in lpContext
should be DWORD aligned. We do not use lpContext argument and lpContext is
optional, so just use NULL.
@@ -371,10 +371,8 @@ static BOOL WINAPI init_once_callback(PINIT_ONCE InitOnce,
APR_DECLARE(apr_status_t) apr_thread_once(apr_thread_once_t *control,
void (*func)(void))
{
- PVOID lpContext;
-
if (!InitOnceExecuteOnce(&control->once, init_once_callback, func,
- &lpContext)) {
+ NULL)) {
return apr_get_os_error();
}
