Displaying 1 result from an estimated 1 matches for "connecting_st".
2008 May 20
10
Asynchronous Pipe::Server problems
...from test_server_async.rb:70:in `mainloop''
from test_server_async.rb:101
Any ideas?
Here''s the code, btw:
# test_server_async.rb
require ''win32/pipe''
include Win32
puts "VERSION: " + Pipe::VERSION
Thread.new { loop { sleep 0.01 } } # Allow Ctrl-C
CONNECTING_STATE = 0
READING_STATE = 1
WRITING_STATE = 2
class MyPipe < Pipe::Server
def connected
puts "connected"
@state = READING_STATE
end
def read_complete
puts "read_complete"
puts "Got [#{buffer}]"
@state = WRITING_STA...