Out of an abundance of caution, NUL out the first byte in the PNP

info.
This commit is contained in:
imp 2018-01-28 23:58:22 +00:00
parent d4635191b7
commit 2e698f572f

View File

@ -90,6 +90,7 @@ ofw_bus_gen_child_pnpinfo_str(device_t cbdev, device_t child, char *buf,
size_t buflen)
{
*buf = '\0';
if (ofw_bus_get_name(child) != NULL) {
strlcat(buf, "name=", buflen);
strlcat(buf, ofw_bus_get_name(child), buflen);