Source-Changes archive

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

CVS commit: [netbsd-9] src/bin/sh



Module Name:    src
Committed By:   martin
Date:           Sun Jun  7 12:50:17 UTC 2020

Modified Files:
        src/bin/sh [netbsd-9]: expand.c expand.h

Log Message:
Pull up following revision(s) (requested by kre in ticket #940):

        bin/sh/expand.h: revision 1.25
        bin/sh/expand.c: revision 1.134
        bin/sh/expand.c: revision 1.135
        bin/sh/expand.c: revision 1.136
        bin/sh/expand.c: revision 1.137

Remove a (completely harmless) duplicate assignment introduced in a
code merge from FreeBSD in 2017.   NFC.

Pointed out by Roland Illig.

prevent sign extension from making expression always false.
remove masking and cast (requested by kre@)

When expanding a here-doc (NXHERE - the type with an unquoted end delim)
the output will not be further processed (at all) so there is no need
to escape magic chars in the output, and doing so leaves stray CTLESC
chars in the here doc text.  Not good.   So don't do that...

To save a strlen() of the result, to determine the size of the here doc,
make rmescapes() return the length of the resulting string (this isn't
needed for other uses, so didn't happen previously).

Reported on current-users@ (2020-02-06) by Jun Ebihara

XXX pullup -9


To generate a diff of this commit:
cvs rdiff -u -r1.132.2.1 -r1.132.2.2 src/bin/sh/expand.c
cvs rdiff -u -r1.24 -r1.24.2.1 src/bin/sh/expand.h

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