Re: [PATCH] sb1000: prevent a potential NULL pointer dereference in sb1000_dev_ioctl()

2007-07-29 Thread Michael Buesch
On Sunday 29 July 2007 21:09, Satyam Sharma wrote: > Hi Michael, > > > On Sun, 29 Jul 2007, Michael Buesch wrote: > > > On Sunday 29 July 2007 20:34:46 Satyam Sharma wrote: > > > (2) !(dev->flags & IFF_UP) is bogus because the functions of this ioctl > > > can (and should) be allowed even when t

Re: [PATCH] sb1000: prevent a potential NULL pointer dereference in sb1000_dev_ioctl()

2007-07-29 Thread Satyam Sharma
Hi Michael, On Sun, 29 Jul 2007, Michael Buesch wrote: > On Sunday 29 July 2007 20:34:46 Satyam Sharma wrote: > > (2) !(dev->flags & IFF_UP) is bogus because the functions of this ioctl > > can (and should) be allowed even when the interface is not up and running. > > Are you _sure_? This funct

Re: [PATCH] sb1000: prevent a potential NULL pointer dereference in sb1000_dev_ioctl()

2007-07-29 Thread Michael Buesch
On Sunday 29 July 2007 20:34:46 Satyam Sharma wrote: > (2) !(dev->flags & IFF_UP) is bogus because the functions of this ioctl > can (and should) be allowed even when the interface is not up and running. Are you _sure_? This function does poke with the device hardware. It might return crap or even

Re: [PATCH] sb1000: prevent a potential NULL pointer dereference in sb1000_dev_ioctl()

2007-07-29 Thread Satyam Sharma
> On Sun, 29 Jul 2007, Domen Puncer wrote: > > > On 29/07/07 00:02 +0200, Jesper Juhl wrote: > > > Hi, > > > > > > Here's a small patch, prompted by a find by the Coverity checker, > > > that removes a potential NULL pointer dereference from > > > drivers/net/sb1000.c::sb1000_dev_ioctl(). > >

Re: [PATCH] sb1000: prevent a potential NULL pointer dereference in sb1000_dev_ioctl()

2007-07-28 Thread Satyam Sharma
On Sun, 29 Jul 2007, Domen Puncer wrote: > On 29/07/07 00:02 +0200, Jesper Juhl wrote: > > Hi, > > > > Here's a small patch, prompted by a find by the Coverity checker, > > that removes a potential NULL pointer dereference from > > drivers/net/sb1000.c::sb1000_dev_ioctl(). > > The checker spo

Re: [PATCH] sb1000: prevent a potential NULL pointer dereference in sb1000_dev_ioctl()

2007-07-28 Thread Domen Puncer
On 29/07/07 00:02 +0200, Jesper Juhl wrote: > Hi, > > Here's a small patch, prompted by a find by the Coverity checker, > that removes a potential NULL pointer dereference from > drivers/net/sb1000.c::sb1000_dev_ioctl(). > The checker spotted that we do a NULL test of 'dev', yet we > dereferenc