Source-Changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

CVS commit: src/bin/sh



Module Name:    src
Committed By:   kre
Date:           Fri May 13 10:32:52 UTC 2016

Modified Files:
        src/bin/sh: eval.c

Log Message:
More fallout from the fix for PR bin/48875 - this one found just by
code reading, rather than any actual real use case failing.

With this script
        f()
        {
                echo hello $1
        }

        exec 3>&1
        echo $(
                for i in a b c
                do
                        echo @$i
                        f >&3
                done >/tmp/foo
        )
        echo foo= $(cat /tmp/foo)

what should be output is

        hello
        hello
        hello

        foo= @a @b @c

but since the (my) 48875 fix the other day, we've been getting

        hello
        @b
        hello
        @c
        hello

        foo= @a

This fixes that.   I think (hope) this is the last of these fixes...


To generate a diff of this commit:
cvs rdiff -u -r1.126 -r1.127 src/bin/sh/eval.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.




Home | Main Index | Thread Index | Old Index