aboutsummaryrefslogtreecommitdiffstats
path: root/thread.c
diff options
context:
space:
mode:
authornormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-05-01 08:35:19 +0000
committernormal <normal@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2018-05-01 08:35:19 +0000
commit9b49e4db8cb755e78b6a7901614c1b015fb41559 (patch)
tree63e09721eaa6be87e49fc70f5a2f1d93895e2ee5 /thread.c
parent008eb062d488fb83dc2dc43f9ac694069f8377d0 (diff)
downloadruby-9b49e4db8cb755e78b6a7901614c1b015fb41559.tar.gz
use list_head_init instead of open-coding it
While we cannot use LIST_HEAD since r63312, we can at least use list_head_init to make our code more readable. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63314 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'thread.c')
-rw-r--r--thread.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/thread.c b/thread.c
index 7ca6625d7c..70338bff38 100644
--- a/thread.c
+++ b/thread.c
@@ -2289,8 +2289,8 @@ void
rb_thread_fd_close(int fd)
{
struct list_head busy;
- busy.n.next = busy.n.prev = &busy.n;
+ list_head_init(&busy);
if (rb_notify_fd_close(fd, &busy)) {
do rb_thread_schedule(); while (!list_empty(&busy));
}