22 Sep
2009
22 Sep
'09
10:49 a.m.
Le 22 sept. 2009 à 12:15, Mikkel Fahnøe Jørgensen a écrit :
How does one create a dispatch source that responds to multiple connections on the same socket, that is, listening on a socket with a backlog larger than 1?
In the online doc it seems that you should have a connected socket to read from, the same way as reading from a file. But documentation also says you need a socket returned from listen().
So where does the accept() call fit into this? Specifically it would be nice to avoid blocking on accept() before creating a read source.
You mean, like a Web server ? http://developer.apple.com/mac/library/samplecode/DispatchWebServer/index.ht...
-- Jean-Daniel