Re: [Bridge] [PATCH] net: bridge: check for a null p->dev before dereferencing it

2018-11-24 Thread David Miller
From: Nikolay Aleksandrov Date: Sat, 24 Nov 2018 14:21:07 +0200 > I was contacted recently about this privately and this was my reply: > "Checking new_nbp() and del_nbp() it should not be possible to reach that code > with p->dev or p->br as NULL. The cap check code has always been there, I just

Re: [Bridge] [PATCH] net: bridge: check for a null p->dev before dereferencing it

2018-11-24 Thread Nikolay Aleksandrov
On 24/11/2018 14:15, Colin King wrote: > From: Colin Ian King > > A recent change added a null check on p->dev after p->dev was being > dereferenced by the ns_capable check on p->dev. Fix this by performing > the p->dev sanity check before it is dereferenced. > > Detected by CoverityScan,

[Bridge] [PATCH] net: bridge: check for a null p->dev before dereferencing it

2018-11-24 Thread Colin King
From: Colin Ian King A recent change added a null check on p->dev after p->dev was being dereferenced by the ns_capable check on p->dev. Fix this by performing the p->dev sanity check before it is dereferenced. Detected by CoverityScan, CID#751490 ("Dereference before null check") Fixes: