| Summary: | accept(2) manpage documents non-existant feature | ||
|---|---|---|---|
| Product: | Documentation | Reporter: | ras <ras> |
| Component: | Books & Articles | Assignee: | freebsd-doc (Nobody) <doc> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | ||
| Priority: | Normal | ||
| Version: | Latest | ||
| Hardware: | Any | ||
| OS: | Any | ||
Richard is right, this feature is non-existant. I'm supplying a patch for the man-page, please review and comment/commit whatever. Thanks Tom Rhodes www.Pittgoth.com www.FreeBSD.org *** accept.2.old Thu Dec 27 16:25:33 2001 --- accept.2 Thu Dec 27 17:07:41 2001 *************** *** 115,137 **** Confirmation can be implied by a normal read or write on the new file descriptor, and rejection can be implied by closing the new socket. - .Pp - One can obtain user connection request data without confirming - the connection by issuing a - .Xr recvmsg 2 - call with an - .Fa msg_iovlen - of 0 and a non-zero - .Fa msg_controllen , - or by issuing a - .Xr getsockopt 2 - request. - Similarly, one can provide user connection rejection information - by issuing a - .Xr sendmsg 2 - call providing only the control information, - or by calling - .Xr setsockopt 2 . .Sh RETURN VALUES The call returns \-1 on error. If it succeeds, it returns a non-negative integer that is a descriptor for the accepted socket. --- 115,120 ---- State Changed From-To: open->closed applied, thanks |
The accept(2) manpage says: One can obtain user connection request data without confirming the con- nection by issuing a recvmsg(2) call with an msg_iovlen of 0 and a non- zero msg_controllen, or by issuing a getsockopt(2) request. Similarly, one can provide user connection rejection information by issuing a sendmsg(2) call providing only the control information, or by calling setsockopt(2). But this is not possible. There is no such code in recvmsg/sendmsg, and no such sockopt. This would be a nice feature, but the handshake on a stream socket should be completed already by the time an accept() call is made... Fix: Nuke the offending paragraph... :P