[PATCH] acpi: syntaxcheck: free lists on error exit return

Keng-Yu Lin keng-yu.lin at canonical.com
Tue Jul 22 08:48:28 UTC 2014


On Tue, Jul 15, 2014 at 8:54 PM, Colin King <colin.king at canonical.com> wrote:
> From: Colin Ian King <colin.king at canonical.com>
>
> Signed-off-by: Colin Ian King <colin.king at canonical.com>
> ---
>  src/acpi/syntaxcheck/syntaxcheck.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/src/acpi/syntaxcheck/syntaxcheck.c b/src/acpi/syntaxcheck/syntaxcheck.c
> index f8daafc..e73d519 100644
> --- a/src/acpi/syntaxcheck/syntaxcheck.c
> +++ b/src/acpi/syntaxcheck/syntaxcheck.c
> @@ -476,6 +476,9 @@ static int syntaxcheck_table(fwts_framework *fw, char *tablename, int which)
>
>         if (fwts_iasl_reassemble(fw, table->data, table->length,
>                                 &iasl_disassembly, &iasl_stdout, &iasl_stderr) != FWTS_OK) {
> +               fwts_text_list_free(iasl_disassembly);
> +               fwts_text_list_free(iasl_stderr);
> +               fwts_text_list_free(iasl_stdout);
>                 fwts_aborted(fw, "Cannot re-assasemble with iasl.");
>                 return FWTS_ERROR;
>         }
> --
> 2.0.1
>
>

Acked-by: Keng-Yu Lin <kengyu at canonical.com>



More information about the fwts-devel mailing list