From 33e9412b186e3a69f0f4a45aee1b7cd321c66622 Mon Sep 17 00:00:00 2001 From: Jeremy Evans Date: Wed, 14 Aug 2019 16:44:11 -0700 Subject: [PATCH] Handle subclasses of Exception in drb This makes it so that client instances that call a method on a server-side object that raise a subclass of Exception are handled similarly to those that raise a subclass of StandardError. Only reraise exceptions that we are fairly sure we don't want to rescue. Fixes [Bug #5618] --- lib/drb/drb.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/drb/drb.rb b/lib/drb/drb.rb index caffd5df25..fac3de5d04 100644 --- a/lib/drb/drb.rb +++ b/lib/drb/drb.rb @@ -1600,7 +1600,9 @@ def perform @result = DRbArray.new(@result) end return @succ, @result - rescue StandardError, ScriptError, Interrupt + rescue NoMemoryError, SystemExit, SystemStackError, SecurityError + raise + rescue Exception @result = $! return @succ, @result end -- 2.22.0