On 8/20/23 6:49 PM, Grisha Levit wrote:
Sorry if it was premature. Btw I'm not sure about the fix for this in
https://git.savannah.gnu.org/cgit/bash.git/diff/execute_cmd.c?h=devel&id=b64a7d8c <https://git.savannah.gnu.org/cgit/bash.git/diff/execute_cmd.c?h=devel&id=b64a7d8c>
Running `! &' still causes the previous command (if any) to be displayed in
`jobs' output:
$ : FOO
$ ! &
[1] 3938
$ jobs
[1]+ Done : FOO
I think this can be addressed by having print_simple_command produce at
least an empty string even if the command has no words and no redirections.
I had fixed this in execute_simple_command with
if (the_printed_command)
the_printed_command[0] = '\0';
before the call to print_simple_command(), but I think I like yours better.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU c...@case.edu http://tiswww.cwru.edu/~chet/