Re: [PATCH] mm/damon/sysfs: eliminate potential uninitialized variable warning

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

 



Hello Deepak,

On Tue, 7 Nov 2023 00:35:55 +0530 Deepak R Varma <drv@xxxxxxxxx> wrote:

> On Mon, Nov 06, 2023 at 05:07:40PM +0300, Dan Carpenter wrote:
> > The "err" variable is not initialized if damon_target_has_pid(ctx) is
> > false and sys_target->regions->nr is zero.
> >
> > Fixes: 0bcd216c4741 ("mm/damon/sysfs: update monitoring target regions for online input commit")
> > Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> 
> Should this be a void function instead as the caller is not checking the return
> value.

As I mentioned on a previous reply[1], I think the caller should check the
return value.  I will send the fix for that soon.

[1] https://lore.kernel.org/damon/20231106165205.48264-1-sj@xxxxxxxxxx/


Thanks,
SJ

> 
> regards,
> deepak.
> 
> >
> >
> 




[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