commit bash-20150918 snapshot

This commit is contained in:
Chet Ramey
2015-09-21 17:02:33 -04:00
parent 2b7361d5c1
commit dcb2f4489f
27 changed files with 266 additions and 39 deletions
+8 -1
View File
@@ -142,6 +142,7 @@ exec_builtin (list)
#endif /* RESTRICTED_SHELL */
args = strvec_from_word_list (list, 1, 0, (int *)NULL);
env = (char **)0;
/* A command with a slash anywhere in its name is not looked up in $PATH. */
command = absolute_program (args[0]) ? args[0] : search_for_command (args[0], 1);
@@ -193,7 +194,10 @@ exec_builtin (list)
adjust_shell_level (-1);
if (cleanenv)
env = (char **)NULL;
{
env = strvec_create (1);
env[0] = (char *)0;
}
else
{
maybe_make_export_env ();
@@ -242,6 +246,9 @@ failed_exec:
if (args)
strvec_dispose (args);
if (env && env != export_env)
strvec_dispose (env);
initialize_traps ();
initialize_signals (1);