]> git.itanic.dy.fi Git - linux-stable/commit
net: usb: pegasus: Check the return value of get_geristers() and friends;
authorPetko Manolov <petkan@nucleusys.com>
Tue, 3 Aug 2021 17:25:23 +0000 (20:25 +0300)
committerSasha Levin <sashal@kernel.org>
Thu, 26 Aug 2021 12:35:38 +0000 (08:35 -0400)
commit735e613fa587bb18386f68724bf036dcdcfaff2c
treeaae2ab4767ea67a55aab93862462798a599c1640
parent6b368411bc0fe60b41b7ce8dbc4fd1f828e9c056
net: usb: pegasus: Check the return value of get_geristers() and friends;

[ Upstream commit 8a160e2e9aeb8318159b48701ad8a6e22274372d ]

Certain call sites of get_geristers() did not do proper error handling.  This
could be a problem as get_geristers() typically return the data via pointer to a
buffer.  If an error occurred the code is carelessly manipulating the wrong data.

Signed-off-by: Petko Manolov <petkan@nucleusys.com>
Reviewed-by: Pavel Skripkin <paskripkin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/usb/pegasus.c