tun: Fix copy/paste error in tun_get_user
Use the right structure while incrementing the offset in tun_get_user.
Signed-off-by: Sridhar Samudrala <sri@us.ibm.com>
Acked-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
diff --git a/drivers/net/tun.c b/drivers/net/tun.c
index 8d82511..d83ccb8 100644
--- a/drivers/net/tun.c
+++ b/drivers/net/tun.c
@@ -571,7 +571,7 @@
if (gso.hdr_len > len)
return -EINVAL;
- offset += sizeof(pi);
+ offset += sizeof(gso);
}
if ((tun->flags & TUN_TYPE_MASK) == TUN_TAP_DEV) {