From 46270f270d7a231e7be24711a760d271c77c5842 Mon Sep 17 00:00:00 2001 From: Julius Pfrommer Date: Mon, 26 Aug 2019 18:17:57 +0200 Subject: [PATCH] feat(multithreading): Prevent use of thread-safe (locked) functions inside the server This gives a warn if a function is used that can potentially lead to a deadlock. --- src/server/ua_server_internal.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/server/ua_server_internal.h b/src/server/ua_server_internal.h index d0d8711395d..ae2e62e2b09 100644 --- a/src/server/ua_server_internal.h +++ b/src/server/ua_server_internal.h @@ -28,6 +28,11 @@ _UA_BEGIN_DECLS +#if UA_MULTITHREADING >= 100 +#undef UA_THREADSAFE +#define UA_THREADSAFE UA_DEPRECATED +#endif + #ifdef UA_ENABLE_PUBSUB #include "ua_pubsub_manager.h" #endif