Skip to content

Commit

Permalink
caif: remove duplicate initialization
Browse files Browse the repository at this point in the history
"priv" is initialized twice.  I kept the second one, because it is next
to the check for NULL.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
Dan Carpenter authored and David S. Miller committed Feb 7, 2012
1 parent bb7d92e commit af2ce21
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions net/caif/chnl_net.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,13 +72,12 @@ static void robust_list_del(struct list_head *delete_node)
static int chnl_recv_cb(struct cflayer *layr, struct cfpkt *pkt)
{
struct sk_buff *skb;
struct chnl_net *priv = container_of(layr, struct chnl_net, chnl);
struct chnl_net *priv;
int pktlen;
const u8 *ip_version;
u8 buf;

priv = container_of(layr, struct chnl_net, chnl);

if (!priv)
return -EINVAL;

Expand Down

0 comments on commit af2ce21

Please sign in to comment.