Thread (2 messages) flat view 2 messages, 2 authors, 2012-05-21

re: NFC: Initial LLCP support

From: Dan Carpenter <hidden>
Date: 2011-12-16 20:26:59
Also in: netdev

Hello Samuel Ortiz,

This is a semi-automatic email about new static checker warnings.

The patch d646960f7986: "NFC: Initial LLCP support" from Dec 14, 
2011, leads to the following Smatch complaint:

net/nfc/llcp/sock.c +47 llcp_sock_bind()
	 warn: variable dereferenced before check 'addr' (see line 45)

net/nfc/llcp/sock.c
    44	
    45		pr_debug("sk %p addr %p family %d\n", sk, addr, addr->sa_family);
                                                                ^^^^^^^^^^^^^^^
New dereference.

    46	
    47		if (!addr || addr->sa_family != AF_NFC)
                     ^^^^
New check.

    48			return -EINVAL;
    49	

regards,
dan carpenter
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help