提交 d0b97e82 编写于 作者: C Cole Robinson

node_device: udev: Fix memory leak

We are setting the same property two different ways without
free'ing in between. Just drop the second assignment.
上级 c198f51a
......@@ -997,11 +997,7 @@ static int udevProcessStorage(struct udev_device *device,
goto out;
}
data->storage.block = strdup(devnode);
if (udevGetStringProperty(device,
"DEVNAME",
&data->storage.block) == PROPERTY_ERROR) {
goto out;
}
if (udevGetStringProperty(device,
"ID_BUS",
&data->storage.bus) == PROPERTY_ERROR) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册