diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2009-06-25 12:03:14 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2009-06-25 12:03:14 +0200 |
commit | d12b9e0c67cc72c9b1631bf2a5611d383e7ad69d (patch) | |
tree | 0e4d79a28d2ac8ed614575eeb4b7b00f9c3e04a3 /runtime/wtp.c | |
parent | db3d5edbe6ac016d99122deeb3da640d7d8864a2 (diff) | |
download | rsyslog-d12b9e0c67cc72c9b1631bf2a5611d383e7ad69d.tar.gz rsyslog-d12b9e0c67cc72c9b1631bf2a5611d383e7ad69d.tar.xz rsyslog-d12b9e0c67cc72c9b1631bf2a5611d383e7ad69d.zip |
some memory accesses are now explicitely atomic
... as far as I think this mostly is to keep the thread debuggers
happy
Diffstat (limited to 'runtime/wtp.c')
-rw-r--r-- | runtime/wtp.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/runtime/wtp.c b/runtime/wtp.c index 611b3f25..218a5db6 100644 --- a/runtime/wtp.c +++ b/runtime/wtp.c @@ -39,6 +39,7 @@ #include <fcntl.h> #include <unistd.h> #include <errno.h> +#include <atomic.h> #ifdef OS_SOLARIS # include <sched.h> @@ -214,7 +215,7 @@ wtpProcessThrdChanges(wtp_t *pThis) */ do { /* reset the change marker */ - pThis->bThrdStateChanged = 0; + ATOMIC_STORE_0_TO_INT(pThis->bThrdStateChanged); /* go through all threads */ for(i = 0 ; i < pThis->iNumWorkerThreads ; ++i) { wtiProcessThrdChanges(pThis->pWrkr[i], LOCK_MUTEX); |