diff options
author | Jason Wang <jasowang@redhat.com> | 2013-12-11 13:08:34 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-01-15 15:27:10 -0800 |
commit | ae8d56de3072a8a812e1400686668315fb27c21b (patch) | |
tree | 5e2d6c2ccbc7c7cda6bf7fdadddce090e6e61aae /net/unix/af_unix.c | |
parent | 693d5d2765cdd89a9f8f113d6a7426ddfe996378 (diff) |
macvtap: signal truncated packets
[ Upstream commit ce232ce01d61b184202bb185103d119820e1260c ]
macvtap_put_user() never return a value grater than iov length, this in fact
bypasses the truncated checking in macvtap_recvmsg(). Fix this by always
returning the size of packet plus the possible vlan header to let the trunca
checking work.
Cc: Vlad Yasevich <vyasevich@gmail.com>
Cc: Zhi Yong Wu <wuzhy@linux.vnet.ibm.com>
Cc: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
Acked-by: Vlad Yasevich <vyasevich@gmail.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'net/unix/af_unix.c')
0 files changed, 0 insertions, 0 deletions