diff options
author | Eric Dumazet <edumazet@google.com> | 2014-02-03 12:52:14 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-02-03 13:01:48 -0800 |
commit | b045d37bd68c20ca88123c2b363cac5e3dae815f (patch) | |
tree | 2a623d5d9a5c3e8a7465a069ce8664897eae53fe /net/ipv4/xfrm4_state.c | |
parent | 4fe46b9a4d0b5eef96867e6d5134159e5a65d2a5 (diff) | |
download | lwn-b045d37bd68c20ca88123c2b363cac5e3dae815f.tar.gz lwn-b045d37bd68c20ca88123c2b363cac5e3dae815f.zip |
ip_tunnel: fix panic in ip_tunnel_xmit()
Setting rt variable to NULL at the beginning of ip_tunnel_xmit()
missed possible use of this variable as a scratch value.
Also fixes a possible dst leak in tunnel_dst_check() :
If we had to call tunnel_dst_reset(), we forgot to
release the reference on dst.
Merges tunnel_dst_get()/tunnel_dst_check() into
a single tunnel_rtable_get() function for clarity.
Many thanks to Tommi for his report and tests.
Fixes: 7d442fab0a67 ("ipv4: Cache dst in tunnels")
Reported-by: Tommi Rantala <tt.rantala@gmail.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Tested-by: Tommi Rantala <tt.rantala@gmail.com>
Cc: Tom Herbert <therbert@google.com>
Cc: Maciej Żenczykowski <maze@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/xfrm4_state.c')
0 files changed, 0 insertions, 0 deletions