From: Jesper Juhl Date: Fri, 17 Aug 2012 10:33:12 +0000 (+0000) Subject: caif: Do not dereference NULL in chnl_recv_cb() X-Git-Tag: v3.6-rc3~10^2~9 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d92c7f8aabae913de16eb855b19cd2002c341896;p=pandora-kernel.git 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: Jesper Juhl Acked-by: Sjur Brændeland Signed-off-by: David S. Miller --- Reading git-diff-tree failed