diff options
author | Jesper Juhl <jj@chaosbits.net> | 2012-05-03 09:38:10 +0800 |
---|---|---|
committer | Len Brown <len.brown@intel.com> | 2012-06-01 11:51:49 -0400 |
commit | 6af1c4fc5227af65092ebc848989693562bfa3e8 (patch) | |
tree | 90c823a42a863c8ec759a89b1c407cd6c7de5477 /drivers/acpi/acpica | |
parent | 76e10d158efb6d4516018846f60c2ab5501900bc (diff) | |
download | linux-6af1c4fc5227af65092ebc848989693562bfa3e8.tar.gz linux-6af1c4fc5227af65092ebc848989693562bfa3e8.tar.bz2 linux-6af1c4fc5227af65092ebc848989693562bfa3e8.zip |
ACPICA: AML Parser: Fix two possible memory leaks in error path
Fixes a couple of memory leaks in the error recovery path.
Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Lin Ming <ming.m.lin@intel.com>
Signed-off-by: Len Brown <len.brown@intel.com>
Diffstat (limited to 'drivers/acpi/acpica')
-rw-r--r-- | drivers/acpi/acpica/psargs.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/acpi/acpica/psargs.c b/drivers/acpi/acpica/psargs.c index 5ac36aba507c..a683d6606e2e 100644 --- a/drivers/acpi/acpica/psargs.c +++ b/drivers/acpi/acpica/psargs.c @@ -618,6 +618,7 @@ static union acpi_parse_object *acpi_ps_get_next_field(struct acpi_parse_state arg = acpi_ps_alloc_op(AML_INT_BYTELIST_OP); if (!arg) { + acpi_ps_free_op(field); return_PTR(NULL); } @@ -662,6 +663,7 @@ static union acpi_parse_object *acpi_ps_get_next_field(struct acpi_parse_state } else { arg = acpi_ps_alloc_op(AML_INT_NAMEPATH_OP); if (!arg) { + acpi_ps_free_op(field); return_PTR(NULL); } |