diff options
Diffstat (limited to 'src/substvars.sh')
-rw-r--r-- | src/substvars.sh | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/substvars.sh b/src/substvars.sh index bc0b052..7c72ed5 100644 --- a/src/substvars.sh +++ b/src/substvars.sh @@ -18,8 +18,8 @@ # along with the ProteanOS Development Kit. If not, see # <http://www.gnu.org/licenses/>. -SUBSTVARS_MAX_DEPTH=50 -SUBSTVAR_TRIM_SED=' +_SUBSTVARS_MAX_DEPTH=50 +_SUBSTVAR_TRIM_SED=' H; # Store each input line in the hold space. ${ # At the last line of input: g; # restore the hold space into the pattern space, @@ -44,7 +44,7 @@ set_substvar() name="$(printf '%s' "${name}" | tr 'A-Z-' 'a-z_')" # Trim leading and trailing whitespace from value. - value="$(printf '%s' "${value}" | sed -n "${SUBSTVAR_TRIM_SED}")" + value="$(printf '%s' "${value}" | sed -n "${_SUBSTVAR_TRIM_SED}")" eval "substvar_${name}=\"\${value}\"" @@ -82,7 +82,7 @@ substvars() # side of the matched space. depth=0 fi - if [ ${depth} -ge ${SUBSTVARS_MAX_DEPTH} ]; then + if [ ${depth} -ge ${_SUBSTVARS_MAX_DEPTH} ]; then # Warn of possible recursion. warn "$(get_msg 'substvar_deep_nesting')" return 1 |