提交 a519d70e 编写于 作者: V Vasiliy Kulikov 提交者: Mauro Carvalho Chehab

[media] media: video: pvrusb2: fix memory leak

Use put_device() instead of kfree() because of device name leak.
Signed-off-by: NVasiliy Kulikov <segoon@openwall.com>
Acked-by: NMike Isely <isely@pobox.com>
Signed-off-by: NMauro Carvalho Chehab <mchehab@redhat.com>
上级 9028f58f
......@@ -647,7 +647,7 @@ static void class_dev_create(struct pvr2_sysfs *sfp,
if (ret) {
pvr2_trace(PVR2_TRACE_ERROR_LEGS,
"device_register failed");
kfree(class_dev);
put_device(class_dev);
return;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册