summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-09-12 13:49:07 +0000
committerakr <akr@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2009-09-12 13:49:07 +0000
commit13e621789e011d8876721a45e46722d38d15f006 (patch)
treeba8637504da3f2409090eba70c93b0f4fbc0e3e0 /lib
parente34c0c896904ea937e18f973af223e63d855a611 (diff)
downloadruby-13e621789e011d8876721a45e46722d38d15f006.tar.gz
ruby-13e621789e011d8876721a45e46722d38d15f006.tar.xz
ruby-13e621789e011d8876721a45e46722d38d15f006.zip
* lib/open-uri.rb (URI::FTP#buffer_open): use the port specified in
the URI. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@24865 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib')
-rw-r--r--lib/open-uri.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/open-uri.rb b/lib/open-uri.rb
index 2a6c544fe..4daec25c0 100644
--- a/lib/open-uri.rb
+++ b/lib/open-uri.rb
@@ -800,7 +800,8 @@ module URI
end
# The access sequence is defined by RFC 1738
- ftp = Net::FTP.open(self.host)
+ ftp = Net::FTP.new
+ ftp.connect(self.host, self.port)
ftp.passive = true if !options[:ftp_active_mode]
# todo: extract user/passwd from .netrc.
user = 'anonymous'