From: "mohit b." Date: 2011-11-29T02:55:26+09:00 Subject: TCPServer' s accept method crashes the ruby program Operating System: Windows XP Ruby Version: ruby 1.9.2p290 (2011-07-09) [i386-mingw32] Program for TCPServer: require "socket" Thread.abort_on_exception = true dts = TCPServer.new('localhost', 20000) begin loop do puts" Inside the Loop to accept Client Request #{dts}" Thread.start(dts.accept_nonblock) do |s| print(s, " is accepted\n") print(s, " is accepted\n") s.write(Time.now) print(s, " is gone\n") s.close end end end Output while running this on WindowsXP Operating system C:\Documents and Settings\verma.r\My Documents\RubyTest>ruby server.rb Inside the Loop to accept Client Request # C:\Documents and Settings\verma.r\My Documents\RubyTest>ruby server.rb Problem: After printing the first puts" Inside the Loop to accept Client Request #{dts}". The programs crashed in Thread.start(dts.accept_nonblock) without even using any client to connect to server. This program is working on some PC and gives this error on other. Has anyone experienced the same problem before. What can be region for the crash please suggest. Thanks -- Posted via http://www.ruby-forum.com/.