diff options
author | marha <marha@users.sourceforge.net> | 2013-02-13 10:41:10 +0100 |
---|---|---|
committer | marha <marha@users.sourceforge.net> | 2013-02-13 10:41:10 +0100 |
commit | b41f74438672dd682bc01ae818cb3da654f22c1e (patch) | |
tree | 07674ef1368a5427a75080528d8cee74234f6b28 /pthreads/tests/cleanup3.c | |
parent | aaf21968deb85b635cb6aa6544df233ea5981346 (diff) | |
download | vcxsrv-b41f74438672dd682bc01ae818cb3da654f22c1e.tar.gz vcxsrv-b41f74438672dd682bc01ae818cb3da654f22c1e.tar.bz2 vcxsrv-b41f74438672dd682bc01ae818cb3da654f22c1e.zip |
Updated to latest CVS version of pthreads
Diffstat (limited to 'pthreads/tests/cleanup3.c')
-rw-r--r-- | pthreads/tests/cleanup3.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/pthreads/tests/cleanup3.c b/pthreads/tests/cleanup3.c index 62317b3b0..7d6a4b96a 100644 --- a/pthreads/tests/cleanup3.c +++ b/pthreads/tests/cleanup3.c @@ -6,10 +6,11 @@ * * Pthreads-win32 - POSIX Threads Library for Win32 * Copyright(C) 1998 John E. Bossom - * Copyright(C) 1999,2005 Pthreads-win32 contributors - * - * Contact Email: rpj@callisto.canberra.edu.au - * + * Copyright(C) 1999,2012 Pthreads-win32 contributors + * + * Homepage1: http://sourceware.org/pthreads-win32/ + * Homepage2: http://sourceforge.net/projects/pthreads4w/ + * * The current list of contributors is contained * in the file CONTRIBUTORS included with the source * code distribution. The list can also be seen at the @@ -98,7 +99,7 @@ typedef struct { CRITICAL_SECTION cs; } sharedInt_t; -static sharedInt_t pop_count = {0, {0}}; +static sharedInt_t pop_count; static void increment_pop_count(void * arg) @@ -146,6 +147,8 @@ main() int i; pthread_t t[NUMTHREADS + 1]; + memset(&pop_count, 0, sizeof(sharedInt_t)); + InitializeCriticalSection(&pop_count.cs); assert((t[0] = pthread_self()).p != NULL); @@ -158,7 +161,7 @@ main() } /* - * Code to control or munipulate child threads should probably go here. + * Code to control or manipulate child threads should probably go here. */ Sleep(1000); |