On Tue, 09 Jan 2007 11:02:35 PST, Amit Choudhary said:
char *broken() {
char *x, *y;
x = kmalloc(100);
y = x;
kfree(x);
x = NULL;
return y;
}
Setting x to NULL doesn't do anything to fix the *real* bug here, because
the problematic reference is held in y, not x. So you never get a crash
because somebody dereferences x.