summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--eshld/eshrt.esh7
1 files changed, 7 insertions, 0 deletions
diff --git a/eshld/eshrt.esh b/eshld/eshrt.esh
index ad03b09..43c4cc6 100644
--- a/eshld/eshrt.esh
+++ b/eshld/eshrt.esh
@@ -101,6 +101,7 @@ __fn_ctxsw()
__fn_update_vars()
{
+ unset IFS
for __var in ${__fn_vars}; do
__val="$(eval "printf '%s' \"\${${__var}}\"" | \
sed "s|'|'\\\\''|g;")"
@@ -111,6 +112,7 @@ __fn_update_vars()
__fn_start()
{
# Hooks.
+ unset IFS
for __fn in ${__fn_begin_hooks}; do
${__fn} ${2}
done
@@ -140,6 +142,7 @@ __fn_start()
__fn_end()
{
# Hooks.
+ unset IFS
for __fn in ${__fn_end_hooks}; do
${__fn} ${__fn_name}
done
@@ -161,6 +164,7 @@ __fn_end()
__tu_end()
{
# Save TU static vars.
+ unset IFS
for __var in $(eval "printf '%s' \"\${__${__tu}_static_vars}\""); do
__val="$(eval "printf '%s' \"\${${__var}}\"" | \
sed "s|'|'\\\\''|g")"
@@ -183,6 +187,7 @@ __stack_trace()
__local()
{
+ unset IFS
for __var in "${@}"; do
case "${__var}" in
*=*)
@@ -209,6 +214,7 @@ static()
printf 'Error: Cannot declare static variables in functions' >&2
exit 1
;; esac
+ unset IFS
for __var in "${@}"; do
case "${__var}" in
*=*)
@@ -253,6 +259,7 @@ eshrtend()
shift 1
cat <<-'EOF'
+unset IFS
for __func in ${__init_funcs}; do
${__func}
done