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_processTerminate.c | |
parent | 8b14911744f58cbe3730703f3fcc41cd969fd0f3 (diff) |
re-indentation, bug fixes, hooks for pre-emptive async cancelation
Diffstat (limited to 'ptw32_processTerminate.c')
-rw-r--r-- | ptw32_processTerminate.c | 31 |
1 files changed, 15 insertions, 16 deletions
diff --git a/ptw32_processTerminate.c b/ptw32_processTerminate.c index 13c564d..13d73aa 100644 --- a/ptw32_processTerminate.c +++ b/ptw32_processTerminate.c @@ -57,13 +57,12 @@ ptw32_processTerminate (void) * ptw32_processInitialized to FALSE * * RESULTS - * N/A + * N/A * * ------------------------------------------------------ */ { - pthread_t thread, - nextThread; + pthread_t thread, nextThread; if (ptw32_processInitialized) { @@ -88,27 +87,27 @@ ptw32_processTerminate (void) ptw32_cleanupKey = NULL; } - EnterCriticalSection(&ptw32_thread_reuse_lock); + EnterCriticalSection (&ptw32_thread_reuse_lock); thread = ptw32_threadReuseTop; while (thread != PTW32_THREAD_REUSE_BOTTOM) - { - nextThread = thread->prevReuse; - free(thread); - thread = nextThread; - } + { + nextThread = thread->prevReuse; + free (thread); + thread = nextThread; + } - LeaveCriticalSection(&ptw32_thread_reuse_lock); + LeaveCriticalSection (&ptw32_thread_reuse_lock); /* * Destroy the global locks. */ - DeleteCriticalSection(&ptw32_spinlock_test_init_lock); - DeleteCriticalSection(&ptw32_rwlock_test_init_lock); - DeleteCriticalSection(&ptw32_cond_test_init_lock); - DeleteCriticalSection(&ptw32_cond_list_lock); - DeleteCriticalSection(&ptw32_mutex_test_init_lock); - DeleteCriticalSection(&ptw32_thread_reuse_lock); + DeleteCriticalSection (&ptw32_spinlock_test_init_lock); + DeleteCriticalSection (&ptw32_rwlock_test_init_lock); + DeleteCriticalSection (&ptw32_cond_test_init_lock); + DeleteCriticalSection (&ptw32_cond_list_lock); + DeleteCriticalSection (&ptw32_mutex_test_init_lock); + DeleteCriticalSection (&ptw32_thread_reuse_lock); ptw32_processInitialized = PTW32_FALSE; } |