On 29/04/2022 19:38, Robert Elz via austin-group-l at The Open Group wrote:
     Date:        Fri, 29 Apr 2022 15:39:23 +0100
     From:        "Geoff Clare via austin-group-l at The Open Group" 
<austin-group-l@opengroup.org>
     Message-ID:  <20220429143923.GA22521@localhost>

   | It also appears that dash still implements remove-before-prompting.

pdksh does as well. However, pdksh is no longer maintained and the maintained shells that derive from pdksh have changed this.

busybox ash and my shell do as well, but both are derived from dash and have merely retained dash's behaviour.

Does anyone not?

bash does not. bosh does not. ksh does not. mksh does not. posh does not. yash does not. zsh does not.

You can test this by doing

  true &
  <press Enter; most shells will show the background command exited>
  wait $!; echo $?

This should print 0. Then do the same, except with the first command changed to false &. That should print 1.

For the record, in my shell, a fork of dash, I have retained the dash behaviour for now because it is unclear to me what the expected behaviour is if a later background job gets the same PID as a previous background job. I consider the dash behaviour a bug, but do not want to fix it in a way that introduces another bug.

Cheers,
Harald van Dijk

  • When can shells remo... Geoff Clare via austin-group-l at The Open Group
    • Re: When can sh... shwaresyst via austin-group-l at The Open Group
    • Re: When can sh... Robert Elz via austin-group-l at The Open Group
      • Re: When ca... Harald van Dijk via austin-group-l at The Open Group
      • Re: When ca... Robert Elz via austin-group-l at The Open Group
        • Re: Whe... Chet Ramey via austin-group-l at The Open Group
          • Re:... Steffen Nurpmeso via austin-group-l at The Open Group
      • Re: When ca... Geoff Clare via austin-group-l at The Open Group
        • Re: Whe... Chet Ramey via austin-group-l at The Open Group
          • wai... Geoff Clare via austin-group-l at The Open Group
            • ... Chet Ramey via austin-group-l at The Open Group
            • ... Robert Elz via austin-group-l at The Open Group
              • ... Chet Ramey via austin-group-l at The Open Group
      • Re: When ca... Geoff Clare via austin-group-l at The Open Group

Reply via email to