Re: ptrace patch fails stress testing

Alan Cox (alan@lxorguk.ukuu.org.uk)
02 Apr 2003 12:49:48 +0100


On Tue, 2003-04-01 at 19:22, linas@austin.ibm.com wrote:
> The problem appears to be that task->mm is dereferenced without
> looking to see if mm is NULL. e.g. in the sched.h in the
> is_dumpable() macro, we have task->mm->dumpable . I'm sitting
> in front of a KDB session and I'm clearly looking at task->mm
> which is NULL.
> Why, how and under what conditions this race condition occurs,
> I don't know. What the best fix is, I don't know.

Zombie process. The patch checks ->mm but must also check ->mm != NULL
first.

> I can try to just add a check for NULL, but I'd like someone
> to tell me that 'yes this is the right way to fix this.'

It is I think.

Alan
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/