From 9c40644850d3a3cf046d09a017524c8983f156eb Mon Sep 17 00:00:00 2001 From: nobu Date: Thu, 4 Dec 2003 12:50:13 +0000 Subject: [PATCH] * lib/drb/drb.rb (DRb::DRbMessage::send_request, send_reply): should rescue errors and re-raise DRbConnError on write too. [ruby-dev:22132] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5110 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 6 ++++++ lib/drb/drb.rb | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/ChangeLog b/ChangeLog index 05e2f26456..65fca1dded 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +Thu Dec 4 21:50:07 2003 Nobuyoshi Nakada + + * lib/drb/drb.rb (DRb::DRbMessage::send_request, send_reply): + should rescue errors and re-raise DRbConnError on write too. + [ruby-dev:22132] + Thu Dec 4 16:41:17 2003 Nobuyoshi Nakada * parse.y (exc_list): allow expanding list. [ruby-dev:22134] diff --git a/lib/drb/drb.rb b/lib/drb/drb.rb index 00d5fa1d23..e9ac40773b 100644 --- a/lib/drb/drb.rb +++ b/lib/drb/drb.rb @@ -582,6 +582,8 @@ module DRb end ary.push(dump(b)) stream.write(ary.join('')) + rescue + raise(DRbConnError, $!.message, $!.backtrace) end def recv_request(stream) # :nodoc: @@ -600,6 +602,8 @@ module DRb def send_reply(stream, succ, result) # :nodoc: stream.write(dump(succ) + dump(result)) + rescue + raise(DRbConnError, $!.message, $!.backtrace) end def recv_reply(stream) # :nodoc: