From: Tanaka Akira Date: 2004-10-08T12:59:55+09:00 Subject: Re: open-uri and ftp problem In article <41658592.6070102@gmx.net>, Henrik Horneber writes: > RTFS'ing *cough* I find that open-uri does this: > > [snip] > ftp = Net::FTP.open(self.host) > ftp.login(user, passwd) > # line 600 in open-uri > ftp.getbinaryfile(self.path, '/dev/null', Net::FTP::DEFAULT_BLOCKSIZE) > [snap] > > > Docs for Net::FTP#getbinaryfile say: > -- > getbinaryfile(remotefile, localfile = File.basename(remotefile), > blocksize = DEFAULT_BLOCKSIZE) {|data| ...} > > Retrieves remotefile in binary mode, storing the result in localfile. If > a block is supplied, it is passed the retrieved data in blocksize chunks. > --- > > > Since I am on Windows, there is no /dev/null to 'store' the file in. > > any clues on what I am doing wrong? I think Net::FTP#getbinaryfile should accept nil as the localfile argument. If so, open-uri can avoid /dev/null. -- Tanaka Akira