X-Git-Url: https://git.karo-electronics.de/?a=blobdiff_plain;f=lib%2Fkobject.c;h=03d4ab349fa749cd907291cc8e36641522d86241;hb=9e5e3661727eaf960d3480213f8e87c8d67b6956;hp=58751bb80a7cbbe905c7d4e752df641ae2240b51;hpb=3de0ef8d0d3350964720cad2a0a72984f1bb81ba;p=karo-tx-linux.git diff --git a/lib/kobject.c b/lib/kobject.c index 58751bb80a7c..03d4ab349fa7 100644 --- a/lib/kobject.c +++ b/lib/kobject.c @@ -976,7 +976,7 @@ const struct kobj_ns_type_operations *kobj_child_ns_ops(struct kobject *parent) { const struct kobj_ns_type_operations *ops = NULL; - if (parent && parent->ktype->child_ns_type) + if (parent && parent->ktype && parent->ktype->child_ns_type) ops = parent->ktype->child_ns_type(parent); return ops;