]> git.baikalelectronics.ru Git - kernel.git/commit
NFC: use after free on error
authorDan Carpenter <dan.carpenter@oracle.com>
Fri, 23 Sep 2011 06:14:35 +0000 (09:14 +0300)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 27 Sep 2011 18:34:10 +0000 (14:34 -0400)
commit7c87d8ae515790eca738457c3c4755fdf9580c56
treecc14065f04168bf10f342b29767d6cfa44e16f9d
parentc906d451206a28e007cac4c9bed1ada07d26f60b
NFC: use after free on error

We returned a freed variable on some error paths when the intent was
to return a NULL.  Part of the reason this was missed was that the
code was confusing because it had too many gotos so I removed them
and simplified the flow a bit.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Lauro Ramos Venancio <lauro.venancio@openbossa.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
net/nfc/nci/core.c