From f9de85b9a35c9f95b390249ea855858c5e4a3ae2 Mon Sep 17 00:00:00 2001 From: Eric Wong Date: Mon, 16 May 2011 20:05:12 +0000 Subject: more reliable shutdown for epoll concurrency models Just close the epoll descriptor, since the sleepy_penguin epoll_wait wrapper may not return EINTR in the future. --- lib/rainbows/xepoll_thread_spawn/client.rb | 1 + 1 file changed, 1 insertion(+) (limited to 'lib/rainbows/xepoll_thread_spawn/client.rb') diff --git a/lib/rainbows/xepoll_thread_spawn/client.rb b/lib/rainbows/xepoll_thread_spawn/client.rb index f8fc191..2ab64d2 100644 --- a/lib/rainbows/xepoll_thread_spawn/client.rb +++ b/lib/rainbows/xepoll_thread_spawn/client.rb @@ -26,6 +26,7 @@ module Rainbows::XEpollThreadSpawn::Client ep = SleepyPenguin::Epoll EP = ep.new + Rainbows.at_quit { EP.close } IN = ep::IN | ep::ET | ep::ONESHOT KATO = {} KATO.compare_by_identity if KATO.respond_to?(:compare_by_identity) -- cgit v1.2.3-24-ge0c7