]> git.ipfire.org Git - thirdparty/systemd.git/commit
util-lib: follow shell syntax for escape in quotes
authorLouis Taylor <louis@kragniz.eu>
Mon, 14 Jan 2019 21:35:10 +0000 (21:35 +0000)
committerLouis Taylor <louis@kragniz.eu>
Thu, 17 Jan 2019 13:42:54 +0000 (13:42 +0000)
commite4a8db1fbd89592899f22fa68e9769e1afc98581
treec19e5c9ef9cb3ea62d2021105b81a32268ead42d
parent80aff27aeb7bbe694395df56be300ff5a4ea4e02
util-lib: follow shell syntax for escape in quotes

Fixes #10659.

This changes the behaviour of parsing environment files to more closely
follow POSIX shell standards.

This has the effect that these variables defined in a file:

    VAR1='\value'
    VAR2="\value"

Are now interpreted as `\value` instead of interpreting the `\`
character and interpreting them as `value`.

For more information about the behaviour followed, see:

http://pubs.opengroup.org/onlinepubs/9699919799/utilities/V3_chap02.html#tag_18_02
src/basic/env-file.c
src/test/test-fileio.c