diff options
author | rpj <rpj> | 2004-05-17 01:38:02 +0000 |
---|---|---|
committer | rpj <rpj> | 2004-05-17 01:38:02 +0000 |
commit | 771465fed0cf50ee2dd790723245fc091699c324 (patch) | |
tree | d8c18d095a33fe7c4564bd90c5f313bb9e4057dd /ptw32_processInitialize.c | |
parent | 8b14911744f58cbe3730703f3fcc41cd969fd0f3 (diff) |
re-indentation, bug fixes, hooks for pre-emptive async cancelation
Diffstat (limited to 'ptw32_processInitialize.c')
-rw-r--r-- | ptw32_processInitialize.c | 37 |
1 files changed, 19 insertions, 18 deletions
diff --git a/ptw32_processInitialize.c b/ptw32_processInitialize.c index a8371ec..de74bc1 100644 --- a/ptw32_processInitialize.c +++ b/ptw32_processInitialize.c @@ -57,22 +57,23 @@ ptw32_processInitialize (void) * ptw32_processInitialized to TRUE. * * RESULTS - * TRUE if successful, - * FALSE otherwise + * TRUE if successful, + * FALSE otherwise * * ------------------------------------------------------ */ { - if (ptw32_processInitialized) { - /* - * Ignore if already initialized. this is useful for - * programs that uses a non-dll pthread - * library. Such programs must call ptw32_processInitialize() explicitly, - * since this initialization routine is automatically called only when - * the dll is loaded. - */ - return PTW32_TRUE; - } + if (ptw32_processInitialized) + { + /* + * Ignore if already initialized. this is useful for + * programs that uses a non-dll pthread + * library. Such programs must call ptw32_processInitialize() explicitly, + * since this initialization routine is automatically called only when + * the dll is loaded. + */ + return PTW32_TRUE; + } ptw32_processInitialized = PTW32_TRUE; @@ -89,12 +90,12 @@ ptw32_processInitialize (void) /* * Set up the global locks. */ - InitializeCriticalSection(&ptw32_thread_reuse_lock); - InitializeCriticalSection(&ptw32_mutex_test_init_lock); - InitializeCriticalSection(&ptw32_cond_list_lock); - InitializeCriticalSection(&ptw32_cond_test_init_lock); - InitializeCriticalSection(&ptw32_rwlock_test_init_lock); - InitializeCriticalSection(&ptw32_spinlock_test_init_lock); + InitializeCriticalSection (&ptw32_thread_reuse_lock); + InitializeCriticalSection (&ptw32_mutex_test_init_lock); + InitializeCriticalSection (&ptw32_cond_list_lock); + InitializeCriticalSection (&ptw32_cond_test_init_lock); + InitializeCriticalSection (&ptw32_rwlock_test_init_lock); + InitializeCriticalSection (&ptw32_spinlock_test_init_lock); return (ptw32_processInitialized); |