]> git.baikalelectronics.ru Git - kernel.git/commit
ipip: fix a regression in ioctl
authorCong Wang <amwang@redhat.com>
Tue, 2 Jul 2013 06:49:34 +0000 (14:49 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 2 Jul 2013 08:13:09 +0000 (01:13 -0700)
commit68700398d99247a991330f67f56c03f41f0c92e8
tree348ddec500211ad6dea16f7725d26ae790446f7b
parent6dad624649409d27a99cbb0d26fba2853e2e8d74
ipip: fix a regression in ioctl

This is a regression introduced by
commit 3b879fe658f251dfac5660 (IPIP: Use ip-tunneling code.)

Similar to GRE tunnel, previously we only check the parameters
for SIOCADDTUNNEL and SIOCCHGTUNNEL, after that commit, the
check is moved for all commands.

So, just check for SIOCADDTUNNEL and SIOCCHGTUNNEL.

Also, the check for i_key, o_key etc. is suspicious too,
which did not exist before, reset them before passing
to ip_tunnel_ioctl().

Cc: Pravin B Shelar <pshelar@nicira.com>
Cc: "David S. Miller" <davem@davemloft.net>
Signed-off-by: Cong Wang <amwang@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ipip.c