Re: [PATCH] Removes extra checking in kernel/cpuset.c

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: James Kosin
Date: Thursday, July 31, 2008 - 11:16 am

Rakib Mullick wrote:

I'd have to NAK this one as well.  2-reasons:
1)  Your patch is guaranteed to generate a NULL pointer dereference at=20
some point.  You keep using cs; and assigning cs =3D cs->parent in the=20
loop, at some point you may end up at the TOP of the tree where=20
cs->parent =3D=3D NULL.
2)  The change breaks the actual meaning of the code.  Which is=20
suggesting my the short snippet, find an entry (while loop)... if the=20
entry is found (if cs test), do this otherwise BUG out.  Your code is=20
saying, if cs is not NULL initially... find someplace then do something. =

  The function never BUGS out unless someone calls with cs NULL initially=
=2E

James Kosin
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH] Removes extra checking in kernel/cpuset.c, James Kosin, (Thu Jul 31, 11:16 am)