Commit Graph

19 Commits

Author SHA1 Message Date
Michael Kerrisk 17805f5b31 Noted the Linux-specific feature whereby setsockopt() doubles
the value given for SO_SNDBUF and SO_RCVBUF.

Noted kernel imposed minimum values for SO_SNDBUF and SO_RCVBUF.
2005-12-15 12:36:08 +00:00
Michael Kerrisk 514d7e5b92 Updated discussion of SO_BSDCOMPAT.
Reformatted some long lines.
2005-12-14 10:27:30 +00:00
Michael Kerrisk 7199370f3a Further refinement of SO_TIMESTAMP from Urs Thuermann. 2005-12-13 10:46:50 +00:00
Michael Kerrisk 7b5c3d0a78 Von: Urs Thuermann <urs@isnogud.escape.de>
An: "Michael Kerrisk" <mtk-manpages@gmx.net>
Betreff: Re: PATCH: man-pages-2.15, socket option SO_TIMESTAMP
Datum: 02 Dec 2005 08:00:11 +0100

Hello Michael,

> Okay -- let me know if your patch is still good to go after you've
> done your reading/testing.  Maybe I will try to do another 
> man-page release tomorrow, if you you can confirm the details in 2.6.

I have compared 2.4 and 2.6 src again and wrote two small test
programs (one sending udp packets, one receiving the packets and
calling SIOCGSTAMP w/ and w/o SO_TIMESTAMP).  Both, 2.4 and 2.6 have
the same behavior, which may be considered a bug.

When a packet is received its timestamp is stored in the sock
structure in kernel for SIOCGSTAMP to be retreived if SO_TIMESTAMP is
not set, otherwise it is written into a cmsg structure to be returned
with the recvmsg syscall.

Therefore, SIOCGSTAMP doesn't get the correct timestamp, when
SO_TIMESTAMP is set.  Instead, SIOCGSTAMP returns an ENOENT error, if
there has never been a packet reception while SO_TIMESTAMP unset,
since the field in the sock structure in the kernel is initialized to
"no timestamp" (0 in 2.4, -1 in 2.6).  Otherwise, SIOCGSTAMP returns
the timestamp found in the sock structure which is from the last
packet when SO_TIMESTAMP was not set, i.e. it may not be the timestamp
of the last packet received.

I have updated the man page socket(7) accordingly.  Patch is below.

urs
2005-12-08 16:36:30 +00:00
Michael Kerrisk d994d57949 Added text noting that select()/poll() do no respect SO_RCVLOWAT. 2005-11-30 16:09:42 +00:00
Michael Kerrisk fb8959ea57 Added FIXME? 2005-11-15 15:00:12 +00:00
Michael Kerrisk 8478ee0279 Formatting fixes 2005-11-02 13:55:25 +00:00
Michael Kerrisk a749f870a8 s/XXX/FIXME/ 2005-10-26 11:27:52 +00:00
Michael Kerrisk 1e32103455 Formatting fixes 2005-10-20 15:11:10 +00:00
Michael Kerrisk b5cc2ffbaa Formatting fixes 2005-10-19 14:48:35 +00:00
Michael Kerrisk e1d6264d9f Manual fixes for parentheses formatting 2005-10-19 07:29:28 +00:00
Michael Kerrisk f8b8dd887d Update description of SO_RCVLOWAT and SO_SNDLOWAT.
(fix derived from Fedora man-pages-2.07-7).
2005-10-04 13:18:49 +00:00
Michael Kerrisk 73b3a56860 Clarified details of use of SO_PEERCRED. 2005-08-16 17:17:16 +00:00
Michael Kerrisk 357cf3fe97 id --> ID 2005-07-18 16:02:32 +00:00
Michael Kerrisk 4d9b698450 Hyphenation/dash fixes 2005-07-06 07:41:37 +00:00
Michael Kerrisk 3df839779c Minor formatting fixes 2005-06-21 14:45:03 +00:00
Michael Kerrisk 8729177b44 global edit s/ -1/ \\-1/g 2005-06-15 14:10:23 +00:00
Michael Kerrisk 305a0578bf Global change of email address for MTK (now: mtk-manpages@gmx.net) 2004-11-03 14:43:40 +00:00
Michael Kerrisk fea681dafb Import of man-pages 1.70 2004-11-03 13:51:07 +00:00