[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [dccp] SOCK_DCCP



Much delayed, but:

On Aug 8, 2005, at 3:35 AM, vladimir.moltchanov at nokia.com wrote:

I am doing an implementation of DCCP as a part of my studies. Its being done as a module for Linux 2.6 and probably for some other OS. So I have spent some time looking at the socket API's.

For TCP sockets, socket, which is listenning is not the one, which is used to serve the connection. So, when request packet comes in and accept() call is pending, a new socket will be created and connection will be bound to that new socket.

Is it the same case with DCCP, or is it so, that listenning socket will start serving the connection with accept() call. On the other hand, it makes whole listen/accept definition relativelly useless because all the advantages of accept queues and backlog value becomes obsolete. We could go around with just connect(), then.

We thought of DCCP ports as being basically like TCP ports, where an endpoint might have multiple connections open to the same local port; the unique identifier is the address/port PAIR. This is an API issue, of course, and someone might choose to implement "one-off" listen() sockets, but it's not what we envisioned.


But in any case, I dont see a reason to call listen on both sides.

I agree: there should be no reason to call listen() on both sides. DCCP is pretty clear that one side should listen()/accept() or equivalent, the other should connect(); the passive endpoint is called the server, the active endpoint the client.


Eddie