Re: [PATCH] bluetooth: kill redundant NULL checks and casts before kfree

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

 



Hi Jesper,

> > > There's no need to check for NULL before calling kfree() on a pointer, and
> > > since kfree() takes a void* argument there's no need to cast pointers to
> > > other types before passing them to kfree().
> > 
> > > +	kfree(hdev->driver_data)	
> > 
> > This won't compile.
> > 
> Ouch. You are right.
> I usually compile test patches, but I have to admit I didn't this time. 
> Sorry about that. Fixed patch below.

the hci_vhci.c change is not needed, because I have a pending update for
that driver that already fixes this. The other two hunks are in my tree
now.

Regards

Marcel


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux