From ec1364fb33cd9a221649eeb362e00a2cfa4a66c1 Mon Sep 17 00:00:00 2001 From: Chet Ramey Date: Tue, 19 May 2015 14:55:02 -0400 Subject: Bash-4.3 patch 34 Change-Id: I4dbb5273a0372ab63d342a11dc9c9d19c002a9ac --- -i | 0 .gitignore | 1 + builtins/set.def | 11 ++++++++--- patchlevel.h | 2 +- 4 files changed, 10 insertions(+), 4 deletions(-) delete mode 100644 -i create mode 100644 .gitignore diff --git a/-i b/-i deleted file mode 100644 index e69de29..0000000 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..e999b2f --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +-i diff --git a/builtins/set.def b/builtins/set.def index c4a7001..9fbbca1 100644 --- a/builtins/set.def +++ b/builtins/set.def @@ -751,9 +751,11 @@ unset_builtin (list) WORD_LIST *list; { int unset_function, unset_variable, unset_array, opt, nameref, any_failed; + int global_unset_func, global_unset_var; char *name; unset_function = unset_variable = unset_array = nameref = any_failed = 0; + global_unset_func = global_unset_var = 0; reset_internal_getopt (); while ((opt = internal_getopt (list, "fnv")) != -1) @@ -761,10 +763,10 @@ unset_builtin (list) switch (opt) { case 'f': - unset_function = 1; + global_unset_func = 1; break; case 'v': - unset_variable = 1; + global_unset_var = 1; break; case 'n': nameref = 1; @@ -777,7 +779,7 @@ unset_builtin (list) list = loptend; - if (unset_function && unset_variable) + if (global_unset_func && global_unset_var) { builtin_error (_("cannot simultaneously unset a function and a variable")); return (EXECUTION_FAILURE); @@ -795,6 +797,9 @@ unset_builtin (list) name = list->word->word; + unset_function = global_unset_func; + unset_variable = global_unset_var; + #if defined (ARRAY_VARS) unset_array = 0; if (!unset_function && valid_array_reference (name)) diff --git a/patchlevel.h b/patchlevel.h index cefe6bd..db8e28c 100644 --- a/patchlevel.h +++ b/patchlevel.h @@ -25,6 +25,6 @@ regexp `^#define[ ]*PATCHLEVEL', since that's what support/mkversion.sh looks for to find the patch level (for the sccs version string). */ -#define PATCHLEVEL 33 +#define PATCHLEVEL 34 #endif /* _PATCHLEVEL_H_ */ -- cgit v1.2.3