提交 22715821 编写于 作者: J Jesper Juhl 提交者: Rafael J. Wysocki

ACPICA: Fix possible memory leak.

Ensure cleanup after a memory allocation failure in dsmethod.c.
Original Linux change from Jesper Juhl.
Signed-off-by: NJesper Juhl <jj@chaosbits.net>
Signed-off-by: NBob Moore <robert.moore@intel.com>
Signed-off-by: NLv Zheng <lv.zheng@intel.com>
Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
上级 75e44460
......@@ -378,7 +378,8 @@ acpi_ds_call_control_method(struct acpi_thread_state *thread,
*/
info = ACPI_ALLOCATE_ZEROED(sizeof(struct acpi_evaluate_info));
if (!info) {
return_ACPI_STATUS(AE_NO_MEMORY);
status = AE_NO_MEMORY;
goto cleanup;
}
info->parameters = &this_walk_state->operands[0];
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册