Re: [PATCH] staging: r8188eu: Remove goto to no-op exit label

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thus wrote Fabio M. De Francesco (fmdefrancesco@xxxxxxxxx):

> > >  	pnpi = netdev_priv(netdev);

> > >  	if (!pnpi->priv)
> > > -		goto RETURN;
> > > +		return;

> I cannot see how pnpi->priv might ever be NULL.

Even if pnpi->priv was NULL, we wouldn't need the check. It's ok to call
vfree(NULL).

> After the two removals I've talked about above, the code will always call 
> vfree(pnpi->priv) and then free_netdev(netdev).

That makes sense.

Best regards,
Martin




[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux