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

From: Stephen Hemminger
Date: Thu Sep 20 2007 - 15:11:00 EST


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

Signed-off-by: Stephen Hemminger <shemminger@xxxxxxxxxxxxxxxxxxxx>


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

--
Stephen Hemminger <shemminger@xxxxxxxxxxxxxxxxxxxx>

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/