Ticket #565 (closed defect: fixed)
GCD sources should return passed-in handle for handle method
| Reported by: | jkh@… | Owned by: | ernest.prabhakar@… |
|---|---|---|---|
| Priority: | blocker | Milestone: | MacRuby 0.6 |
| Component: | MacRuby | Keywords: | |
| Cc: |
Description
In this small example of a socket source:
s = TCPServer.open(hostname, port) src = Dispatch::Source.new(Dispatch::Source::READ, s, 0, q) { |src|
sock = src.handle sock.accept
}
You don't actually get the original handle back and therefore cannot call the accept function on it. Sources should encapsulate the original handle so that you can safely get it inside the handler block.
Change History
Note: See
TracTickets for help on using
tickets.

