Re: [bug report] scsi: core: Fix possible memory leak if device_add() fails

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

 



On Thu, Aug 10, 2023 at 08:05:21PM +0800, wangzhu wrote:
> Hello Dan Carpenter:
> 
> 
> Sorry for the patch 04b5b5cb0136 I submitted, I thought put_dev(&rc->dev) is
> not the same as kfree(rc).
> 
> Then should I submit a revert patch again, or you can fix it yourself?
> please let me know what I can do.

The original code was buggy and the new code is slightly buggier.

Instead of reverting, lets see if anyone knows the correct way to fix
this.  If no one comments within a week then I agree that reverting is
better than a double free.

regards,
dan carpenter




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]

  Powered by Linux