summaryrefslogtreecommitdiffstats
path: root/lib/common.sh
diff options
context:
space:
mode:
authorP. J. McDermott <pjm@nac.net>2012-09-08 17:58:02 (EDT)
committer P. J. McDermott <pjm@nac.net>2012-09-08 17:58:02 (EDT)
commitf51a642dd3bd46d3254c8ac07bcfadf0b7b9ddc2 (patch)
tree76b84cffcadf8034c8d0fce4b031893819f28659 /lib/common.sh
parentdbb1d617f03dd47c4cb4235f937e7560c3a0fd86 (diff)
Make sure that _ob_return only unsets variables.
According to POSIX.1-2008, some conformant shells might try to unset a function if: 1. Neither -f nor -v is specified and 2. A variable by a specified name does not exist.
Diffstat (limited to 'lib/common.sh')
-rw-r--r--lib/common.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/common.sh b/lib/common.sh
index a11d6e4..73293d7 100644
--- a/lib/common.sh
+++ b/lib/common.sh
@@ -31,7 +31,7 @@ _ob_local()
_ob_return()
{
# Unset the variables at the top of the stack.
- unset ${_OB_STACK_VARS##*|}
+ unset -v ${_OB_STACK_VARS##*|}
# Pop the variable list from the top of the stack.
_OB_STACK_VARS="${_OB_STACK_VARS%|*}"