Re: [PATCH] gpio: sim: fix a memory leak

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

 



On Thu, Feb 16, 2023 at 3:42 PM Andy Shevchenko
<andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:
>
> On Thu, Feb 16, 2023 at 03:15:55PM +0100, Bartosz Golaszewski wrote:
> > Fix an inverted logic bug in gpio_sim_remove_hogs() that leads to GPIO
> > hog structures never being freed.
>
> Ha-ha, I stared to this code, and in the head I was "okay, this loop is until
> chip_label is *not* NULL, so should be fine".
>
> At the same time, "! is hard to process", see for example
> 2754435d4c82 ("ACPI / battery: get rid of negations in conditions")
> which I had suggested.
>
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
>
> P.S. But my patch I mentioned looks also good to have, no?
>

I don't think it matters. In fact - I'm not sure if the order was
accidental or not anymore. :( If you want to discuss it further -
please resend it as a regular patch on the list.

Bart



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux