On 18/03/2025 20:49, Lawrence Velázquez via austin-group-l at The Open Group wrote:
On Tue, Mar 18, 2025, at 8:55 AM, Geoff Clare via austin-group-l at The Open 
Group wrote:
I disagree - as per my earlier email, quoted at the end of the bug
description, the standard says "one input file descriptor from another",
implying that they are two different file descriptors, so the behaviour
of 0<&0 is currently unspecified (implicitly).

Is the behavior of this rationale example unspecified as well?

        Since the connection of the input to the equivalent of
        /dev/null is considered to occur before redirections, the
        following script would produce no output:

        exec < /etc/passwd
        cat <&0 &
        wait

https://pubs.opengroup.org/onlinepubs/9799919799.2024edition/xrat/V4_xcu_chap01.html#tag_23_02_09_12

Huh. Thanks for finding that, I did completely missed it. At the very least, that makes it rather explicit what the intent was, even if it provides no reason for it.

Cheers,
Harald van Dijk

        • ... Harald van Dijk via austin-group-l at The Open Group
          • ... Geoff Clare via austin-group-l at The Open Group
            • ... Harald van Dijk via austin-group-l at The Open Group
              • ... Geoff Clare via austin-group-l at The Open Group
              • ... Harald van Dijk via austin-group-l at The Open Group
              • ... Steffen Nurpmeso via austin-group-l at The Open Group
              • ... Chet Ramey via austin-group-l at The Open Group
            • ... Chet Ramey via austin-group-l at The Open Group
          • ... Chet Ramey via austin-group-l at The Open Group
        • ... Lawrence Velázquez via austin-group-l at The Open Group
          • ... Harald van Dijk via austin-group-l at The Open Group
  • [1003.1(20... Austin Group Issue Tracker via austin-group-l at The Open Group
  • [1003.1(20... Austin Group Issue Tracker via austin-group-l at The Open Group
  • [1003.1(20... Austin Group Issue Tracker via austin-group-l at The Open Group
  • [1003.1(20... Austin Group Issue Tracker via austin-group-l at The Open Group
  • Fwd: Re: [... Chet Ramey via austin-group-l at The Open Group
    • Re: F... Geoff Clare via austin-group-l at The Open Group
      • R... Chet Ramey via austin-group-l at The Open Group
        • ... Geoff Clare via austin-group-l at The Open Group
          • ... Chet Ramey via austin-group-l at The Open Group
            • ... Geoff Clare via austin-group-l at The Open Group

Reply via email to