mirror of
https://https.git.savannah.gnu.org/git/bash.git
synced 2026-08-08 11:12:36 +02:00
commit bash-20040121 snapshot
This commit is contained in:
@@ -2300,6 +2300,11 @@ makunbound (name, vc)
|
||||
We also need to add it back into the correct hash table. */
|
||||
if (old_var && local_p (old_var) && variable_context == old_var->context)
|
||||
{
|
||||
/* Reset the attributes. Preserve the export attribute if the variable
|
||||
came from a temporary environment. Make sure it stays local, and
|
||||
make it invisible. */
|
||||
old_var->attributes = (exported_p (old_var) && tempvar_p (old_var)) ? att_exported : 0;
|
||||
VSETATTR (old_var, att_local);
|
||||
VSETATTR (old_var, att_invisible);
|
||||
FREE (value_cell (old_var));
|
||||
var_setvalue (old_var, (char *)NULL);
|
||||
|
||||
Reference in New Issue
Block a user