Skip to content
Commit d92c7f8a authored by Jesper Juhl's avatar Jesper Juhl Committed by David S. Miller
Browse files

caif: Do not dereference NULL in chnl_recv_cb()



In net/caif/chnl_net.c::chnl_recv_cb() we call skb_header_pointer()
which may return NULL, but we do not check for a NULL pointer before
dereferencing it.
This patch adds such a NULL check and properly free's allocated memory
and return an error (-EINVAL) on failure - much better than crashing..

Signed-off-by: default avatarJesper Juhl <jj@chaosbits.net>
Acked-by: default avatarSjur Brændeland <sjur.brandeland@stericsson.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 6c71bec6
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment