Re: [PATCH 38/44] kdbus: Fix error path in kdbus_user_lookup()

2015-10-09 Thread Sergei Zviagintsev
Hi David, On Thu, Oct 08, 2015 at 05:06:57PM +0200, David Herrmann wrote: > Hi > > On Thu, Oct 8, 2015 at 1:32 PM, Sergei Zviagintsev wrote: > > If idr_alloc() fails, we shouldn't call idr_remove() as latter produces > > warning when called on non-allocated ids. Split cleanup code into three > >

Re: [PATCH 38/44] kdbus: Fix error path in kdbus_user_lookup()

2015-10-08 Thread David Herrmann
Hi On Thu, Oct 8, 2015 at 1:32 PM, Sergei Zviagintsev wrote: > If idr_alloc() fails, we shouldn't call idr_remove() as latter produces > warning when called on non-allocated ids. Split cleanup code into three > parts for differrent cleanup scenarios before and after idr_alloc(). > > Signed-off-by

[PATCH 38/44] kdbus: Fix error path in kdbus_user_lookup()

2015-10-08 Thread Sergei Zviagintsev
If idr_alloc() fails, we shouldn't call idr_remove() as latter produces warning when called on non-allocated ids. Split cleanup code into three parts for differrent cleanup scenarios before and after idr_alloc(). Signed-off-by: Sergei Zviagintsev --- ipc/kdbus/domain.c | 20 ++--