Re: Process id recycling and status of tasks

From: Leonidas .
Date: Sun Oct 25 2009 - 06:49:30 EST


> The obvious question which follows from above is what would be the correct
> way to determine whether a process is alive or not using pid_alive()? Using
> pid_task() does not seem correct and seemingly correct way looks unfeasible.
>

I guess, just checking task_struct->exit_state will be okay to do,
right? If exit
state is DEAD then the task is stale, might avoid using the reference counting
counterparts, right?

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