]> granicus.if.org Git - libevent/commitdiff
Fix BEV_LOCK/BEV_UNLOCK macros for EVENT__DISABLE_THREAD_SUPPORT
authorAzat Khuzhin <azat@libevent.org>
Sat, 9 Jul 2022 12:38:56 +0000 (15:38 +0300)
committerAzat Khuzhin <azat@libevent.org>
Sat, 9 Jul 2022 14:17:06 +0000 (17:17 +0300)
bufferevent-internal.h

index 3ad0acf0f0255d88fa744a5ee88f20163ad99782..8db48d12503613347cb35923269686055ad3d0a3 100644 (file)
@@ -485,8 +485,8 @@ bufferevent_socket_set_conn_address_(struct bufferevent *bev, struct sockaddr *a
 #define BEV_UPCAST(b) EVUTIL_UPCAST((b), struct bufferevent_private, bev)
 
 #ifdef EVENT__DISABLE_THREAD_SUPPORT
-#define BEV_LOCK(b) EVUTIL_NIL_STMT_
-#define BEV_UNLOCK(b) EVUTIL_NIL_STMT_
+#define BEV_LOCK(b) (void)(b)
+#define BEV_UNLOCK(b) (void)(b)
 #else
 /** Internal: Grab the lock (if any) on a bufferevent */
 #define BEV_LOCK(b) do {                                               \