Skip to content

RuntimeError with TCPServer.accept #26

@zzak

Description

@zzak

I'm trying to write the following program:

soc = TCPServer.new('localhost', 9999)
fd = soc.accept
puts fd.to_i

But when I connect, like:

soc = TCPSocket.new('localhost', 9999)

I get the following backtrace:

trace:
        [1] /Users/zscott/code/mruby-bartender/mruby/build/mrbgems/mruby-socket/mrblib/socket.rb:276:in TCPServer.accept
        [0] test.rb:2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions