From: Dmitry Torokhov Date: Tue, 26 Apr 2005 07:29:58 +0000 (-0500) Subject: [PATCH] kobject_hotplug() should use kobject_name() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=eb11d8ffceead1eb3d84366f1687daf2217e883e;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git [PATCH] kobject_hotplug() should use kobject_name() kobject: kobject_hotplug should use kobject_name() instead of accessing kobj->name directly since for objects with long names it can contain garbage. Signed-off-by: Dmitry Torokhov Signed-off-by: Greg Kroah-Hartman --- diff --git a/lib/kobject_uevent.c b/lib/kobject_uevent.c index 2a4e7671eaf..1ede5aa3337 100644 --- a/lib/kobject_uevent.c +++ b/lib/kobject_uevent.c @@ -246,7 +246,7 @@ void kobject_hotplug(struct kobject *kobj, enum kobject_action action) if (hotplug_ops->name) name = hotplug_ops->name(kset, kobj); if (name == NULL) - name = kset->kobj.name; + name = kobject_name(&kset->kobj); argv [0] = hotplug_path; argv [1] = name;