ruby-changes:65421
From: Nobuyoshi <ko1@a...>
Date: Mon, 8 Mar 2021 19:47:08 +0900 (JST)
Subject: [ruby-changes:65421] 8c943e3be8 (master): Make the flag in thread_exclusive unique
https://git.ruby-lang.org/ruby.git/commit/?id=8c943e3be8 From 8c943e3be880eef40023e52daf43d8e0bc8ab59c Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada <nobu@r...> Date: Tue, 23 Feb 2021 21:26:36 +0900 Subject: Make the flag in thread_exclusive unique --- win32/win32.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/win32/win32.c b/win32/win32.c index 027303b..83443df 100644 --- a/win32/win32.c +++ b/win32/win32.c @@ -705,8 +705,9 @@ static st_table *conlist = NULL; https://github.com/ruby/ruby/blob/trunk/win32/win32.c#L705 #define conlist_disabled ((st_table *)-1) #define thread_exclusive(obj) \ - for (bool first = (EnterCriticalSection(&obj##_mutex), true); \ - first; first = (LeaveCriticalSection(&obj##_mutex), false)) + for (bool exclusive_for_##obj = (EnterCriticalSection(&obj##_mutex), true); \ + exclusive_for_##obj; \ + exclusive_for_##obj = (LeaveCriticalSection(&obj##_mutex), false)) static char *uenvarea; -- cgit v1.1 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/