[lkml]   [2003]   [Aug]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: [PATCH] revert zap_other_threads breakage, disallow CLONE_THREAD without CLONE_DETACHED

On Tue, 12 Aug 2003, Roland McGrath wrote:
> Please apply this patch to get us back out of this useless quagmire and
> disallow the problematic case that noone wants to try to use any more.
> - if ((clone_flags & CLONE_THREAD) && !(clone_flags & CLONE_SIGHAND))
> + if ((clone_flags & CLONE_THREAD) &&
> return ERR_PTR(-EINVAL);
> if ((clone_flags & CLONE_DETACHED) && !(clone_flags & CLONE_THREAD))

Look at the condition that follows: it disallows CLONE_DETACHED for

Which really means that together with the first change, CLONE_DETACHED is
always the same thing as CLONE_THREAD: you can't have one without the

Which means that they are logically not separate bits any more, and we
should just get rid of CLONE_DETACHED altogether, and use CLONE_THREAD in
all cases where it is tested for.

I'd really prefer not to keep a bit around that has to mean the same thing
as another bit - that way just lies madness. So I'll document
CLONE_DETACHED as being a no-op, and change the _one_ place that used it
to just use CLONE_THREAD instead.


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at
Please read the FAQ at

 \ /
  Last update: 2009-11-18 23:46    [W:0.100 / U:4.184 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site