On Wed, 24 Mar 2010 14:59:46 -0600 Jonathan Corbet <corbet@xxxxxxx> wrote: > On Wed, 24 Mar 2010 13:33:47 -0700 > Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> wrote: > > > > + VM_BUG_ON(cc == NULL); > > > > It's a bit strange to test this when we're about to oops anyway. The > > oops will tell us the same thing. > > ...except that we've seen a fair number of null pointer dereference > exploits that have told us something altogether different. Are we > *sure* we don't want to test for null pointers...? > It's hard to see what the test gains us really - the kernel has zillions of pointer derefs, any of which could be NULL if we have a bug. Are we more likely to have a bug here than elsewhere? This one will oops on a plain old read, so it's a bit moot in this case. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@xxxxxxxxxx For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: <a href=mailto:"dont@xxxxxxxxx"> email@xxxxxxxxx </a>