ACK: [PATCH] fwts: opal: fix memory leak of 'buf'.
Alex Hung
alex.hung at canonical.com
Thu Jul 4 17:41:27 UTC 2019
On 2019-07-04 10:08 a.m., Colin King wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> Each iteration is leaking an allocated buffer. Free it.
>
> Addresses-Coverity: ("Resource leak")
> Fixes: 80eda6b3aad3 ("fwts/opal: Reserved memory DT validation tests.")
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
> src/opal/reserv_mem.c | 1 +
> 1 file changed, 1 insertion(+)
>
> diff --git a/src/opal/reserv_mem.c b/src/opal/reserv_mem.c
> index 69233b2c..8708295e 100644
> --- a/src/opal/reserv_mem.c
> +++ b/src/opal/reserv_mem.c
> @@ -234,6 +234,7 @@ static int reserv_mem_limits_test(fwts_framework *fw)
> buf);
> ok = false;
> }
> + free(buf);
>
> if (skip)
> continue;
>
Acked-by: Alex Hung <alex.hung at canonical.com>
More information about the fwts-devel
mailing list