mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-25 04:13:08 +00:00
Use ENV_USER with vars set via function -a
ENV_USER is intended to be used when setting any variable whose name is controlled by the user. The names given to `function -a` certainly qualifies. This wasn't an issue in practice because the only restriction ENV_USER imposes is also imposed on ENV_LOCAL, but the rules may change in the future.
This commit is contained in:
parent
3f11d90744
commit
6d7a7b00d7
1 changed files with 1 additions and 1 deletions
|
@ -602,7 +602,7 @@ void parse_util_set_argv(const wchar_t * const *argv, const wcstring_list_t &nam
|
|||
size_t i;
|
||||
for (i=0, arg=argv; i < named_arguments.size(); i++)
|
||||
{
|
||||
env_set(named_arguments.at(i).c_str(), *arg, ENV_LOCAL);
|
||||
env_set(named_arguments.at(i).c_str(), *arg, ENV_LOCAL | ENV_USER);
|
||||
|
||||
if (*arg)
|
||||
arg++;
|
||||
|
|
Loading…
Reference in a new issue