Skip to content
Commit bc6f2a75 authored by YueHaibing's avatar YueHaibing Committed by Jessica Yu
Browse files

kernel/module: Fix mem leak in module_add_modinfo_attrs

In module_add_modinfo_attrs if sysfs_create_file
fails, we forget to free allocated modinfo_attrs
and roll back the sysfs files.

Fixes: 03e88ae1

 ("[PATCH] fix module sysfs files reference counting")
Reviewed-by: default avatarMiroslav Benes <mbenes@suse.cz>
Signed-off-by: default avatarYueHaibing <yuehaibing@huawei.com>
Signed-off-by: default avatarJessica Yu <jeyu@kernel.org>
parent 8d1b73dd
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment