[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20151019125750.GG7340@mwanda>
Date: Mon, 19 Oct 2015 15:57:50 +0300
From: Dan Carpenter <dan.carpenter@...cle.com>
To: Julia Lawall <Julia.Lawall@...6.fr>
Cc: Lauro Ramos Venancio <lauro.venancio@...nbossa.org>,
kernel-janitors@...r.kernel.org,
Aloisio Almeida Jr <aloisio.almeida@...nbossa.org>,
Samuel Ortiz <sameo@...ux.intel.com>,
"David S. Miller" <davem@...emloft.net>,
linux-wireless@...r.kernel.org, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/2] NFC: delete null dereference
The next goto after that is messed up as well:
1056 dev = nfc_get_device(idx);
1057 if (!dev)
1058 return -ENODEV;
1059
1060 device_lock(&dev->dev);
1061
1062 local = nfc_llcp_find_local(dev);
1063 if (!local) {
1064 nfc_put_device(dev);
It should not call nfc_put_device() because that happens after goto
exit.
1065 rc = -ENODEV;
1066 goto exit;
1067 }
regards,
dan carpenter
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists