- unquoted_glob_pattern_p: when in a bracket expression (open > 0),
don't allow an unquoted slash as part of the bracket expression.
Report from Stephane Chazelas <stephane.chazelas@gmail.com>
+
+ 7/1
+ ---
+print_cmd.c
+ - print_function_def,named_function_string: make sure to call
+ PRINT_DEFERRED_HEREDOCS to finish printing any here documents and
+ delimiters before printing the function closing brace. Fixes bug
+ reported by Denis McKeon <dmckeon@swcp.com>
+
+execute_cmd.c
+ - execute_command_internal: call reap_procsubs at the end of executing
+ a group command on systems that have /dev/fd. Fixes bug reported by
+ kfm@plushkava.net
+
+ 7/3
+ ---
+jobs.c
+ - waitchld: this is in the potential SIGCHLD path, so don't call
+ bgp_add, which can potentially call malloc. The glibc malloc doesn't
+ handle that well. Report from howaboutsynergy@protonmail.com
+
+ 7/5
+ ---
+builtins/bind.def
+ - bind_builtin: make sure return_code is >= 0 before returning it.
+ Fixes bug with bind -x and invalid key sequences reported by
+ bashbug@jonkmans.nl
run_unwind_frame ("bind_builtin");
+ if (return_code < 0)
+ return_code = EXECUTION_FAILURE;
+
return (sh_chkwrite (return_code));
}
return (last_command_exit_value = EXECUTION_FAILURE);
}
-#if 0
- if (redirection_undo_list)
- {
- /* XXX - why copy here? */
- my_undo_list = (REDIRECT *)copy_redirects (redirection_undo_list);
- dispose_partial_redirects ();
- }
- else
- my_undo_list = (REDIRECT *)NULL;
-#else
my_undo_list = redirection_undo_list;
redirection_undo_list = (REDIRECT *)NULL;
-#endif
-#if 0
- if (exec_redirection_undo_list)
- {
- /* XXX - why copy here? */
- exec_undo_list = (REDIRECT *)copy_redirects (exec_redirection_undo_list);
- dispose_exec_redirects ();
- }
- else
- exec_undo_list = (REDIRECT *)NULL;
-#else
exec_undo_list = exec_redirection_undo_list;
exec_redirection_undo_list = (REDIRECT *)NULL;
-#endif
if (my_undo_list || exec_undo_list)
begin_unwind_frame ("loop_redirections");
case cm_while:
case cm_until:
case cm_for:
+ case cm_group:
# if defined (ARITH_FOR_COMMAND)
case cm_arith_for:
# endif
}
executing_list++;
QUIT;
+#if 1
execute_command (command->value.Connection->first);
+#else
+ execute_command_internal (command->value.Connection->first,
+ asynchronous, pipe_in, pipe_out,
+ fds_to_close);
+#endif
+
QUIT;
optimize_fork (command); /* XXX */
exec_result = execute_command_internal (command->value.Connection->second,
if (command->value.Connection->first)
command->value.Connection->first->flags |= CMD_IGNORE_RETURN;
+#if 1
exec_result = execute_command (command->value.Connection->first);
+#else
+ exec_result = execute_command_internal (command->value.Connection->first, 0, NO_PIPE, NO_PIPE, fds_to_close);
+#endif
QUIT;
if (((command->value.Connection->connector == AND_AND) &&
(exec_result == EXECUTION_SUCCESS)) ||
/* Only manipulate the list of process substitutions while SIGCHLD
is blocked. */
if ((ind = find_procsub_child (pid)) >= 0)
- {
- set_procsub_status (ind, pid, WSTATUS (status));
- bgp_add (pid, WSTATUS (status));
- }
+ set_procsub_status (ind, pid, WSTATUS (status));
#endif
/* It is not an error to have a child terminate that we did
make_command_string_internal (cmdcopy->type == cm_group
? cmdcopy->value.Group->command
: cmdcopy);
- /* XXX - PRINT_DEFERRED_HEREDOCS (""); ? */
+ PRINT_DEFERRED_HEREDOCS ("");
remove_unwind_protect ();
indentation -= indentation_amount;
make_command_string_internal (cmdcopy->type == cm_group
? cmdcopy->value.Group->command
: cmdcopy);
- /* XXX - PRINT_DEFERRED_HEREDOCS (""); ? */
+ PRINT_DEFERRED_HEREDOCS ("");
indentation = old_indent;
indentation_amount = old_amount;
if (fifo_list[i].proc != (pid_t)-1 && fifo_list[i].proc > 0)
{
r = wait_for (fifo_list[i].proc);
+ /* add to bgpids list? have to make interface public */
fifo_list[i].proc = (pid_t)-1;
}
}
if (dev_fd_list[i] != (pid_t)-1 && dev_fd_list[i] > 0)
{
r = wait_for (dev_fd_list[i]);
+ /* add to bgpids list? have to make interface public */
dev_fd_list[i] = (pid_t)-1;
}
}
argv[1] = <\$foo>
argv[2] = <\$foo>
argv[1] = <mixed\$foo/>
+<abcdefg>
+<.>
+*abc.c
+searchable/.
+searchable/./.
+readable/\.
+readable/\./.
+searchable/\.
+readable/\.
+searchable/.
+searchable/.
+searchable/.
+1: [qwe/qwe]
+2: [qwe/
+3: [qwe/]
+4:
+5: [qwe/
+6:
argv[1] = <a>
argv[2] = <abc>
argv[3] = <abd>
argv[3] = <abd>
argv[4] = <abe>
tmp/l1 tmp/l2 tmp/*4 tmp/l3
-./glob.tests: line 48: no match: tmp/*4
+./glob.tests: line 50: no match: tmp/*4
argv[1] = <bdir/>
argv[1] = <*>
argv[1] = <a*>