summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-10-27 16:46:46 (EDT)
committer P. J. McDermott <pjm@nac.net>2012-10-27 16:46:46 (EDT)
commitbb839b71b05c8123b345ac3c36dccc1a49e053f7 (patch)
treeaa8b8ad79f874265a0d0b86dbe9c496b7e0b1602 /lib
parent03d4d284dbef7976c0f368696eb33a9247e9714e (diff)
Improve IFS resetting in ob_reduce_deps().
Diffstat (limited to 'lib')
-rw-r--r--lib/deps.sh9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/deps.sh b/lib/deps.sh
index 3f54386..853e55b 100644
--- a/lib/deps.sh
+++ b/lib/deps.sh
@@ -174,8 +174,7 @@ ob_parse_dep()
ob_reduce_deps()
{
_ob_local _obrd_opt _obrd_host_arch _obrd_host_plat _obrd_deps \
- _obrd_orig_ifs _obrd_dep_and _obrd_dep_or \
- _obrd_dep_list _obrd_dep_or_list _obrd_dep
+ _obrd_dep_and _obrd_dep_or _obrd_dep_list _obrd_dep_or_list _obrd_dep
_obrd_union='false'
@@ -205,15 +204,14 @@ ob_reduce_deps()
return ${?}
fi
- _obrd_orig_ifs="${IFS}"
IFS=','
for _obrd_dep_and in ${_obrd_deps}; do
- IFS="${_obrd_orig_ifs}"
+ unset IFS
if ! ${_obrd_union}; then
IFS='|'
_obrd_dep_or_list=
for _obrd_dep_or in ${_obrd_dep_and}; do
- IFS="${_obrd_orig_ifs}"
+ unset IFS
_obrd_dep="$(ob_parse_dep -a "${_obrd_host_arch}" \
-P "${_obrd_host_plat}" "${_obrd_dep_or}")"
if [ -n "${_obrd_dep}" ]; then
@@ -240,6 +238,7 @@ ob_reduce_deps()
fi
fi
done
+ unset IFS
echo "${_obrd_dep_list}"