mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-09 08:51:14 -03:00
always define argv for scripts
Found when testing what breaks when dereferencing undefined vars is an errors (#4163). Fixes #4181
This commit is contained in:
@@ -434,6 +434,8 @@ int main(int argc, char **argv) {
|
||||
}
|
||||
|
||||
env_set(L"argv", sb.c_str(), 0);
|
||||
} else {
|
||||
env_set(L"argv", NULL, 0);
|
||||
}
|
||||
|
||||
const wcstring rel_filename = str2wcstring(file);
|
||||
|
||||
Reference in New Issue
Block a user