diff options
Diffstat (limited to 'runtime/glbl.c')
-rw-r--r-- | runtime/glbl.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/runtime/glbl.c b/runtime/glbl.c index 5951d21a..278bc4e1 100644 --- a/runtime/glbl.c +++ b/runtime/glbl.c @@ -74,7 +74,9 @@ static uchar *pszDfltNetstrmDrvrCAF = NULL; /* default CA file for the netstrm d static uchar *pszDfltNetstrmDrvrKeyFile = NULL; /* default key file for the netstrm driver (server) */ static uchar *pszDfltNetstrmDrvrCertFile = NULL; /* default cert file for the netstrm driver (server) */ static int bTerminateInputs = 0; /* global switch that inputs shall terminate ASAP (1=> terminate) */ +#ifndef HAVE_ATOMIC_BUILTINS static DEF_ATOMIC_HELPER_MUT(mutTerminateInputs); +#endif #ifdef USE_UNLIMITED_SELECT static int iFdSetSize = howmany(FD_SETSIZE, __NFDBITS) * sizeof (fd_mask); /* size of select() bitmask in bytes */ #endif @@ -131,7 +133,7 @@ SIMP_PROP_SET(DfltNetstrmDrvrCertFile, pszDfltNetstrmDrvrCertFile, uchar*) /* TO */ static int GetGlobalInputTermState(void) { - return ATOMIC_FETCH_32BIT(bTerminateInputs); + return ATOMIC_FETCH_32BIT(&bTerminateInputs, &mutTerminateInputs); } |