On 02/13, Mika Penttilä wrote:
>
> > +int de_thread(struct task_struct *tsk)
> >  {
> >     struct signal_struct *sig = tsk->signal;
> >     struct sighand_struct *oldsighand = tsk->sighand;
> > @@ -1051,60 +1100,24 @@ static int de_thread(struct task_struct *tsk)
> >     if (thread_group_empty(tsk))
> >             goto no_thread_group;
> >
> > -   /*
> > -    * Kill all other threads in the thread group.
> > -    */
> >     spin_lock_irq(lock);
> > -   if (signal_group_exit(sig)) {
> > -           /*
> > -            * Another group action in progress, just
> > -            * return so that the signal is processed.
> > -            */
> > -           spin_unlock_irq(lock);
> > -           return -EAGAIN;
> > -   }
> > -
> > -   sig->group_exit_task = tsk;
> > -   sig->notify_count = zap_other_threads(tsk);
> > +   sig->notify_count = sig->nr_threads;
>
>
> maybe nr_threads - 1 since nr_threads includes us ?

Damn. Of course you are right, thanks a lot! Please see v2.

Hmm. I didn't even notice my own test-case didn't pass because of this
off-by-one.

Oleg.

Reply via email to