aboutsummaryrefslogtreecommitdiff
path: root/src/zencore/include
diff options
context:
space:
mode:
authorStefan Boberg <[email protected]>2023-11-16 15:34:25 +0100
committerGitHub <[email protected]>2023-11-16 15:34:25 +0100
commit3d16e8a64e9ef76f407270ef092671a1be7bf346 (patch)
treea354559a0a3e857b8a6f3e292c9c9cd25ba87bc5 /src/zencore/include
parent0.2.34 (diff)
downloadzen-3d16e8a64e9ef76f407270ef092671a1be7bf346.tar.xz
zen-3d16e8a64e9ef76f407270ef092671a1be7bf346.zip
changed posix event implementation to use std::atomic instead of volatile (#547)
Diffstat (limited to 'src/zencore/include')
-rw-r--r--src/zencore/include/zencore/thread.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/zencore/include/zencore/thread.h b/src/zencore/include/zencore/thread.h
index 9f2671610..47f37c9a3 100644
--- a/src/zencore/include/zencore/thread.h
+++ b/src/zencore/include/zencore/thread.h
@@ -10,6 +10,8 @@
#include <string_view>
#include <vector>
+#define ZEN_USE_WINDOWS_EVENTS ZEN_PLATFORM_WINDOWS
+
namespace zen {
void SetCurrentThreadName(std::string_view ThreadName);
@@ -107,7 +109,7 @@ public:
ZENCORE_API bool Wait(int TimeoutMs = -1);
ZENCORE_API void Close();
-#if ZEN_PLATFORM_WINDOWS
+#if ZEN_USE_WINDOWS_EVENTS
inline void* GetWindowsHandle() { return m_EventHandle; }
#endif