[lkml]   [2003]   [Feb]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
Patch in this message
SubjectRe: sendmsg and IP_PKTINFO
"David S. Miller" <> writes:

> All you are showing us Neil is that the documentation
> is inaccurate. That snippet you showed me from manual
> pages is wrong about sendmsg semantics.

Yes, it's wrong I agree. Here is a patch. Please check
and if nobody complains Andries can apply.

> The ifindex you specify does mean "send out this interface".
> It is very surprising that this documentation is wrong since
> the likely author (Andi Kleen) is smart enough to read the
> actual implementation when he writes these things.

There was no serious technical review of these manpages ever, so
I wouldn't be surprised if there are more such technical errors (hint ;)


--- ip.7~ 2003-02-19 08:50:48.000000000 +0100
+++ ip.7 2003-02-19 09:09:36.000000000 +0100
@@ -260,12 +260,16 @@
is passed to
.BR sendmsg (2)
-then the outgoing packet will be sent over the interface
-specified in
-.B ipi_ifindex
-with the destination address set to
+.\" This field is grossly misnamed
.B ipi_spec_dst
+is not zero then it is used as the local source address for the routing
+table lookup and for setting up IP source route options.
+.B ipi_ifindex
+is not zero the primary local address of the interface specified by the index overwrites
+.I ipi_spec_dst
+for the routing table lookup.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2005-03-22 13:33    [W:0.049 / U:0.316 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site