• Sven Eckelmann's avatar
    batman-adv: Fix parameter order of hlist_add_behind · e050dbeb
    Sven Eckelmann authored
    1d023284 ("list: fix order of arguments for
    hlist_add_after(_rcu)") was incorrectly rebased on top of
    d9124268 ("batman-adv: Fix out-of-order
    fragmentation support"). The parameter order change of the rebased patch was
    not re-applied as expected. This causes a memory leak and can cause crashes
    when out-of-order packets are received. hlist_add_behind will try to access the
    uninitalized list pointers of frag_entry_new to find the previous/next entry
    and may modify/read random memory locations.
    Signed-off-by: default avatarSven Eckelmann <sven@narfation.org>
    Cc: Andrew Morton <akpm@linux-foundation.org>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    e050dbeb
fragmentation.c 14.7 KB