Gentoo Archives: gentoo-commits

From: Patrick McLean <chutzpah@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/netifrc:master commit in: init.d/
Date: Wed, 31 Mar 2021 01:11:12
Message-Id: 1617153048.bef5edf9d2d1fcd982ae19a7cb05dc2d58b854e7.chutzpah@OpenRC
1 commit: bef5edf9d2d1fcd982ae19a7cb05dc2d58b854e7
2 Author: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
3 AuthorDate: Wed Mar 31 01:06:31 2021 +0000
4 Commit: Patrick McLean <chutzpah <AT> gentoo <DOT> org>
5 CommitDate: Wed Mar 31 01:10:48 2021 +0000
6 URL: https://gitweb.gentoo.org/proj/netifrc.git/commit/?id=bef5edf9
7
8 net.lo.in: quote variables in _configure_variables
9
10 The variables being passed to eval aren't quoted either in the before-eval
11 scope, or in what is passed to eval. Make sure they are quoted.
12
13 Signed-off-by: Patrick McLean <chutzpah <AT> gentoo.org>
14
15 init.d/net.lo.in | 4 ++--
16 1 file changed, 2 insertions(+), 2 deletions(-)
17
18 diff --git a/init.d/net.lo.in b/init.d/net.lo.in
19 index 06304e1..0bb69f3 100644
20 --- a/init.d/net.lo.in
21 +++ b/init.d/net.lo.in
22 @@ -225,9 +225,9 @@ _configure_variables()
23 for var in ${_config_vars}; do
24 local v=
25 for t; do
26 - eval v=\$${var}_${t}
27 + eval v="\"\$${var}_${t}\""
28 if [ -n "${v}" ]; then
29 - eval ${var}_${IFVAR}=\$${var}_${t}
30 + eval "${var}_${IFVAR}=\"\$${var}_${t}\""
31 continue 2
32 fi
33 done