* [PATCH] ACPI, hp-wmi: Fix memory leak in acpi query
@ 2010-11-18 16:46 Zeng Zhaoming
2010-11-24 16:53 ` Matthew Garrett
0 siblings, 1 reply; 2+ messages in thread
From: Zeng Zhaoming @ 2010-11-18 16:46 UTC (permalink / raw)
To: platform-driver-x86; +Cc: mjg, Zeng Zhaoming
Free acpi return memory after query.
Signed-off-by: Zeng Zhaoming <zengzm.kernel@gmail.com>
---
drivers/platform/x86/hp-wmi.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
mode change 100644 => 100755 drivers/platform/x86/hp-wmi.c
diff --git a/drivers/platform/x86/hp-wmi.c b/drivers/platform/x86/hp-wmi.c
old mode 100644
new mode 100755
index 1dac659..9e05af9
--- a/drivers/platform/x86/hp-wmi.c
+++ b/drivers/platform/x86/hp-wmi.c
@@ -172,6 +172,8 @@ static int hp_wmi_perform_query(int query, int write, u32 *buffer,
bios_return = *((struct bios_return *)obj->buffer.pointer);
memcpy(buffer, &bios_return.value, sizeof(bios_return.value));
+
+ kfree(obj);
return 0;
}
--
1.7.0.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] ACPI, hp-wmi: Fix memory leak in acpi query
2010-11-18 16:46 [PATCH] ACPI, hp-wmi: Fix memory leak in acpi query Zeng Zhaoming
@ 2010-11-24 16:53 ` Matthew Garrett
0 siblings, 0 replies; 2+ messages in thread
From: Matthew Garrett @ 2010-11-24 16:53 UTC (permalink / raw)
To: Zeng Zhaoming; +Cc: platform-driver-x86
Applied, thanks.
--
Matthew Garrett | mjg59@srcf.ucam.org
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-11-24 16:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-18 16:46 [PATCH] ACPI, hp-wmi: Fix memory leak in acpi query Zeng Zhaoming
2010-11-24 16:53 ` Matthew Garrett
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.