As I understand it, according to the recvmsg() manual page, if the packet
being returned is larger than the buffer provided, and the protocol does not
support piecemeal reception of data, then:
(1) the buffer should be filled,
(2) MSG_TRUNC should be set in msg_flags, and
(3) the length of the full packet, including the discarded bit should be
returned.
AF_NETLINK sockets, however, do not do (3). See this bit in netlink_recvmsg():
copied = skb->len;
if (len < copied) {
msg->msg_flags |= MSG_TRUNC;
copied = len;
}
Or is this only true if the caller of recvmsg() passes MSG_TRUNC in?
David
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at http://vger.kernel.org/majordomo-info.html