Re: [patch] target/iscsi: double free in lio_target_tiqn_addtpg()

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

 



On Thu, Dec 15, 2016 at 04:43:55PM +0100, Bart Van Assche wrote:
> On 12/13/2016 01:27 PM, Dan Carpenter wrote:
> > This iscsit_tpg_add_portal_group() function is only called from
> > lio_target_tiqn_addtpg().  Both functions free the "tpg" pointer on
> > error so it's a double free bug.  The memory is allocated in the caller
> > so it should be freed in the caller and not here.
> > 
> > Fixes: e48354ce078c ("iscsi-target: Add iSCSI fabric support for target v4.1")
> > Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> 
> Hello Dan,
> 
> Do you think a "Cc: stable" tag should be added to this patch?
> 

It will basically only fail for allocation errors.  It's probably not
super likely.  These are static checker fixes, not something I
encountered in real life.

regards,
dan carpenter
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Kernel Development]     [Kernel Announce]     [Kernel Newbies]     [Linux Networking Development]     [Share Photos]     [IDE]     [Security]     [Git]     [Netfilter]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Device Mapper]

  Powered by Linux