mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-07-20 02:12:51 +02:00
commit bash-20130419 snapshot
This commit is contained in:
@@ -315,7 +315,8 @@ declare_internal (list, local_var)
|
||||
}
|
||||
else
|
||||
#endif
|
||||
if (STREQ (name, value))
|
||||
/* disallow self references at global scope */
|
||||
if (STREQ (name, value) && variable_context == 0)
|
||||
{
|
||||
builtin_error (_("%s: nameref variable self references not allowed"), name);
|
||||
assign_error++;
|
||||
|
||||
+1
-1
@@ -863,7 +863,7 @@ unset_builtin (list)
|
||||
}
|
||||
else
|
||||
#endif /* ARRAY_VARS */
|
||||
tem = unset_function ? unbind_func (name) : unbind_variable (name);
|
||||
tem = unset_function ? unbind_func (name) : (nameref ? unbind_nameref (name) : unbind_variable (name));
|
||||
|
||||
/* This is what Posix.2 says: ``If neither -f nor -v
|
||||
is specified, the name refers to a variable; if a variable by
|
||||
|
||||
Reference in New Issue
Block a user