summaryrefslogtreecommitdiff
path: root/net/ceph
diff options
context:
space:
mode:
authorStefano Brivio <sbrivio@redhat.com>2019-01-02 13:29:27 +0100
committerDavid S. Miller <davem@davemloft.net>2019-01-02 10:29:20 -0800
commit7adf3246092f5e87ed0fa610e8088fae416c581f (patch)
treea1f95986879abc9bcc2dfcb296cfe0d64683fd3f /net/ceph
parent202700e30740c6568b5a6943662f3829566dd533 (diff)
ipv6: route: Fix return value of ip6_neigh_lookup() on neigh_create() error
In ip6_neigh_lookup(), we must not return errors coming from neigh_create(): if creation of a neighbour entry fails, the lookup should return NULL, in the same way as it's done in __neigh_lookup(). Otherwise, callers legitimately checking for a non-NULL return value of the lookup function might dereference an invalid pointer. For instance, on neighbour table overflow, ndisc_router_discovery() crashes ndisc_update() by passing ERR_PTR(-ENOBUFS) as 'neigh' argument. Reported-by: Jianlin Shi <jishi@redhat.com> Fixes: f8a1b43b709d ("net/ipv6: Create a neigh_lookup for FIB entries") Signed-off-by: Stefano Brivio <sbrivio@redhat.com> Reviewed-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ceph')
0 files changed, 0 insertions, 0 deletions