From 0d59cd79cc791047842a98d210b5a35267ba3602 Mon Sep 17 00:00:00 2001 From: shugo Date: Tue, 6 Feb 2007 09:45:28 +0000 Subject: * lib/net/ftp.rb: moved fixes for EPIPE to the correct place. [ruby-core:10204] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11643 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- ChangeLog | 5 +++++ lib/net/ftp.rb | 28 ++++++++++++++-------------- 2 files changed, 19 insertions(+), 14 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5541c62877..4b3354c005 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Tue Feb 6 18:43:17 2007 Shugo Maeda + + * lib/net/ftp.rb: moved fixes for EPIPE to the correct + place. [ruby-core:10204] + Tue Feb 6 16:38:08 2007 Koichi Sasada * vm_opts.h: set properties: diff --git a/lib/net/ftp.rb b/lib/net/ftp.rb index 26f4da277b..9b231291af 100644 --- a/lib/net/ftp.rb +++ b/lib/net/ftp.rb @@ -291,13 +291,6 @@ module Net putline(cmd) voidresp end - rescue Errno::EPIPE - # EPIPE, in this case, means that the data connection was unexpectedly - # terminated. Rather than just raising EPIPE to the caller, check the - # response on the control connection. If getresp doesn't raise a more - # appropriate exception, re-raise the original exception. - getresp - raise end def sendport(host, port) @@ -434,13 +427,6 @@ module Net voidresp end end - rescue Errno::EPIPE - # EPIPE, in this case, means that the data connection was unexpectedly - # terminated. Rather than just raising EPIPE to the caller, check the - # response on the control connection. If getresp doesn't raise a more - # appropriate exception, re-raise the original exception. - getresp - raise end # @@ -492,6 +478,13 @@ module Net voidresp end end + rescue Errno::EPIPE + # EPIPE, in this case, means that the data connection was unexpectedly + # terminated. Rather than just raising EPIPE to the caller, check the + # response on the control connection. If getresp doesn't raise a more + # appropriate exception, re-raise the original exception. + getresp + raise end # @@ -517,6 +510,13 @@ module Net voidresp end end + rescue Errno::EPIPE + # EPIPE, in this case, means that the data connection was unexpectedly + # terminated. Rather than just raising EPIPE to the caller, check the + # response on the control connection. If getresp doesn't raise a more + # appropriate exception, re-raise the original exception. + getresp + raise end # -- cgit v1.2.3