This looks very similar to the telnet problem I reported a few weeks back (ruby talk 10469 most recently) -- like my problem, the line of code causing the error is dealing with TCPSocket. I wasn't using RubyWin, so I don't think that's the problem. Noel > -----Original Message----- > From: nosuzuki / e-mail.ne.jp [mailto:nosuzuki / e-mail.ne.jp]On Behalf Of > Carl Youngblood > Sent: Friday, February 16, 2001 11:40 AM > To: ruby-talk ML; ruby-talk / netlab.co.jp > Subject: [ruby-talk:10974] Problem with Windows Installation 1.6.2 > > > I just downloaded the Windows Installation 1.6.2 and tried to run the > example on page 113-114 of PROGRAMMING RUBY and I'm getting an error. Any > ideas on what might be wrong? Here is the code: > > require 'net/http' > > pages = %w( www.rubycentral.com > www.awl.com > www.pragmaticprogrammer.com > ) > > threads = [] > > for page in pages > threads << Thread.new(page) { |myPage| > > h = Net::HTTP.new(myPage, 80) > puts "Fetching: #{myPage}" > resp, data = h.get('/', nil) > puts "Got #{myPage}: #{resp.message}" > } > end > > threads.each { |aThread| aThread.join } > > ---------------------- > > And here is the output I get: > > Fetching: www.rubycentral.com > Fetching: www.awl.com > Fetching: www.pragmaticprogrammer.com > > /cygdrive/c/ruby/lib/ruby/1.6/net/protocol.rb:427:in `new': Invalid > argument - "connect(2)"(Errno::EINVAL) > > from /cygdrive/c/ruby/lib/ruby/1.6/net/protocol.rb:427:in `new' > from Ruby1:20:in `join' > from Ruby1:20 > from Ruby1:20:in `each' > from Ruby1:20 > from Ruby1:20 > > Any help would be greatly appreciated. I'm new to Ruby, so I'm not very > familiar with the windows install and any of its peculiarities. > Also, as a > side note, I tried to run the pig.rbw and the scroll.rbw examples in the > samples\tk directory and they both crashed RubyWin.exe. FYI, I'm running > Windows 2000 Server. I ran a Net::HTTP test last night on my home machine > (win2k professional) using version 1.6.1 and didn't have this > error. Could > the latest windows install perhaps have introduced some more problems? > Thanks in advance for your time. > > Carl Youngblood > > >