1
0
Fork 0

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>
hifive-unleashed-5.1
Jesper Juhl 2012-05-03 09:38:10 +08:00 committed by Len Brown
parent 76e10d158e
commit 6af1c4fc52
1 changed files with 2 additions and 0 deletions

View File

@ -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);
}