Bug#317747: [Pkg-shadow-devel] Bug#317747: su -m / suspend / fg broken with zsh

Alexander Gattin "Alexander Gattin" <arg@online.com.ua>, 317747@bugs.debian.org
Mon Jul 11 12:07:31 UTC 2005


Hi!

On Mon, 11 Jul 2005 03:32:17 -0700 (PDT)
  dean gaudet <dean@arctic.org> wrote:
> at first i tried just adding the setpgrp...

You mean if(setpgrp()) exit(1);?

> but with that the su'd zsh doesn't ever seem to wake up.
> 
> so i threw in the TIOCSPGRP calls to pass the tty pgrp
> to the su'd zsh...
> and that fixes it.

Thanks for your time and good analysis.

> it looks like bash calls TIOCSPGRP directly to set the
> tty pgrp when it is
> continued... whereas zsh calls TIOCGPGRP to check it and
> then goes back to
> sleep because it doesn't own the tty.

You have done my job. ;)

> ugh.  this is a gross...  i'm leaning towards blaming
> zsh for the tty pgrp
> problems, but blaming su for the lack of setpgrp -- su
> really needs to protect itself from being put to sleep
> by its child accidentally.

This will be done but in other way -- just by ignoring 
TSTP.
Is this OK with you?

-- 
WBR,
xrgtn





More information about the Pkg-shadow-devel mailing list