From f0940220c89e240e3af746c96cda5fed5305bb82 Mon Sep 17 00:00:00 2001 From: Kevin Clark Date: Wed, 18 Jun 2008 01:20:13 +0000 Subject: [PATCH] rb: Fix the timeout used for joining threads when calling shutdown(timeout) on NonblockingServer git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@669040 13f79535-47bb-0310-9956-ffa450edef68 --- lib/rb/lib/thrift/server/nonblockingserver.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/rb/lib/thrift/server/nonblockingserver.rb b/lib/rb/lib/thrift/server/nonblockingserver.rb index 70a58b52..f84a1090 100644 --- a/lib/rb/lib/thrift/server/nonblockingserver.rb +++ b/lib/rb/lib/thrift/server/nonblockingserver.rb @@ -197,7 +197,7 @@ module Thrift start = Time.now @worker_threads.each do |t| if shutdown_timeout > 0 - timeout = Time.now - (start + shutdown_timeout) + timeout = (start + shutdown_timeout) - Time.now break if timeout <= 0 t.join(timeout) else -- 2.17.1