[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20120423204118.GD13075@kroah.com>
Date: Mon, 23 Apr 2012 13:41:18 -0700
From: greg <gregkh@...uxfoundation.org>
To: yan <clouds.yan@...il.com>
Cc: kernel <linux-kernel@...r.kernel.org>,
message <message.get@...il.com>
Subject: Re: [PATCH 4/4][Trivial] lib/kobject.c : check parameter in
kobject_init_and_add
On Sat, Apr 21, 2012 at 06:17:49PM +0800, yan wrote:
> If user turns to the simple interface kobject_init_and_add
> and gives a null kobject, kobject_init can detect it but
> just dumps the stack. Then there is:
> -->kobject_add_varg
> -->kobject_set_name_vargs
> In the end, it will reference kobj->name and we have an oops.
>
> Check whether we have a valid kobject in kobject_init_and_add.
Why would anyone ever call this function without a valid kobject?
Again, sorry, this patch isn't ok.
greg k-h
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists