[PATCH 2/3] missing null termination in power supply uevent

Stephen Hemminger
2007-09-20T19:10:59Z

[-- Attachment #1: sysfs-power.patch --]
[-- Type: text/plain, Size: 551 bytes --]

Need to null terminate environment. Found by inspection
while looking for similar problems to platform uevent bug

Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org>

--- a/drivers/power/power_supply_sysfs.c 2007-08-18 07:50:10.000000000 -0700
+++ b/drivers/power/power_supply_sysfs.c 2007-09-20 11:42:11.000000000 -0700
@@ -289,6 +289,7 @@ int power_supply_uevent(struct device *d
if (ret)
goto out;
}
+ envp[i] = NULL;

out:
free_page((unsigned long)prop_buf);