]> git.baikalelectronics.ru Git - kernel.git/commit
ip_tunnel: Don't allow to add the same tunnel multiple times.
authorSteffen Klassert <steffen.klassert@secunet.com>
Mon, 22 Sep 2014 07:11:08 +0000 (09:11 +0200)
committerDavid S. Miller <davem@davemloft.net>
Fri, 26 Sep 2014 04:41:30 +0000 (00:41 -0400)
commitbf7f59fc8d92b3ceca53c1305b74b96ce4b992fe
tree9a1c59c0c7fa60a3bc2c86c8e918addd14ab6d15
parentad4bdac1bc7de74b8622672516da69920f1a4279
ip_tunnel: Don't allow to add the same tunnel multiple times.

When we try to add an already existing tunnel, we don't return
an error. Instead we continue and call ip_tunnel_update().
This means that we can change existing tunnels by adding
the same tunnel multiple times. It is even possible to change
the tunnel endpoints of the fallback device.

We fix this by returning an error if we try to add an existing
tunnel.

Signed-off-by: Steffen Klassert <steffen.klassert@secunet.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ip_tunnel.c