]> git.ipfire.org Git - thirdparty/bash.git/blob - CHANGES
Bash-5.2 patch 26: fix typo when specifying readline's custom color prefix
[thirdparty/bash.git] / CHANGES
1 This document details the changes between this version, bash-5.2-release, and
2 the previous version, bash-5.2-rc4.
3
4 1. Changes to Bash
5
6 2. Changes to Readline
7
8 a. When replacing a history entry, make sure the existing entry has a non-NULL
9 timestamp before copying it; it may have been added by the application, not
10 the history library.
11
12 3. New Features in Bash
13
14 4. New Features in Readline
15
16 ------------------------------------------------------------------------------
17 This document details the changes between this version, bash-5.2-rc4, and
18 the previous version, bash-5.2-rc3.
19
20 1. Changes to Bash
21
22 a. Changed how the compatibility mode enabling of extglob works in conjunction
23 with parsing conditional commands.
24
25 b. Fixed a problem with aliases containing command substitutions.
26
27 2. Changes to Readline
28
29 3. New Features in Bash
30
31 4. New Features in Readline
32
33 ------------------------------------------------------------------------------
34 This document details the changes between this version, bash-5.2-rc3, and
35 the previous version, bash-5.2-rc2.
36
37 1. Changes to Bash
38
39 a. Added a compatibility mode feature that causes the parser to parse command
40 substitutions as if extglob were enabled. If it is enabled before execution,
41 parse at execution will succeed. If not, the subsequent execution parse will
42 fail.
43
44 b. Fixed an issue with handling a `return' executed in a trap action if the
45 trap is executed while running in a shell function.
46
47 2. Changes to Readline
48
49 3. New Features in Bash
50
51 4. New Features in Readline
52
53 a. Readline now checks for changes to locale settings (LC_ALL/LC_CTYPE/LANG)
54 each time it is called, and modifies the appropriate locale-specific display
55 and key binding variables when the locale changes.
56
57 ------------------------------------------------------------------------------
58 This document details the changes between this version, bash-5.2-rc2, and
59 the previous version, bash-5.2-rc1.
60
61 1. Changes to Bash
62
63 a. Fixed a bug that could disable history saving after a compound array
64 assignment in an interactive shell.
65
66 b. Fixed a bug that could cause incorrect error messages when running a DEBUG
67 trap during a conditional or arithmetic command.
68
69 c. Fixed a bug that caused test to print an error message when given ! ! arg
70 as arguments.
71
72 d. Fixed a bug that resulted in incorrect error messages when completing a
73 backquoted command substitution.
74
75 e. Changed command substitution parsing to reproduce the original text more
76 closely when reconsituting the command string from the parsed command.
77
78 f. Fixed a bug that could cause an EXIT trap to use the wrong variable context
79 when the errexit option is set.
80
81 g. Fixed a bug that could cause the parser to incorrectly delimit a token when
82 an alias expansion ended with a multibyte character.
83
84 2. Changes to Readline
85
86 3. New Features in Bash
87
88 a. Since there is no `declare -' equivalent of `local -', make sure to use
89 `local -' in the output of `local -p'.
90
91 b. Null anchored matches in pattern substitution now process `&' in the
92 replacement string, like sed.
93
94 4. New Features in Readline
95
96 ------------------------------------------------------------------------------
97 This document details the changes between this version, bash-5.2-rc1, and
98 the previous version, bash-5.2-beta.
99
100 1. Changes to Bash
101
102 a. Changes to `wait -p' and how it sets the variable name in the presence of
103 valid and invalid PID arguments.
104
105 b. Fixed a bug that caused compgen to dump core if the completion engine was
106 not initialized.
107
108 c. Fixed a memory leak in the variable name programmable completion code.
109
110 d. Here-documents and here-strings use tempfiles if the shell compatibility
111 level is 50 or lower.
112
113 e. Non-interactive shells exit on a syntax error encountered while parsing a
114 command substitution.
115
116 f. Fixed a bug with inherited parser state while parsing a command substitution.
117
118 g. Fixed a bug that caused the shell not to check for terminating signals
119 after executing the command_string supplied with `-c' and before executing
120 the exit trap.
121
122 h. Changes to avoid a make race condition while generating builtins.c.
123
124 i. Make it explicit that BASH_REMATCH is always a global variable, and that
125 local copies are (currently) ignored.
126
127 j. Fixed a bug that caused an ambiguous redirection (>&word) to be printed
128 incorrectly (>&word) if no file descriptor was supplied.
129
130 2. Changes to Readline
131
132 a. Fixed a bug that caused rl_eof_found to be set prematurely while reading a
133 multi-character key sequence in callback mode.
134
135 3. New Features in Bash
136
137 a. In posix mode, the `printf' builtin checks for the `L' length modifier and
138 uses long double for floating point conversion specifiers if it's present,
139 double otherwise.
140
141 b. The `globbing' completion code now takes the `globstar' option into account.
142
143 c. `suspend -f' now forces the shell to suspend even if job control is not
144 currently enabled.
145
146 4. New Features in Readline
147
148 ------------------------------------------------------------------------------
149 This document details the changes between this version, bash-5.2-beta, and
150 the previous version, bash-5.2-alpha.
151
152 1. Changes to Bash
153
154 a. Fixed a problem with command-oriented history and multi-line commands that
155 caused embedded blank lines to be run together.
156
157 b. Changed the way `&' is quoted when performing pattern substitution and
158 `patsub_replacement' is enabled.
159
160 c. Fixed some integer overflows when expanding strings or reading the output
161 of command substitution larger than 2GB.
162
163 d. `wait -p' without the `-n' option now does something useful if there are no
164 jobs.
165
166 e. Fixed an issue with read timeouts in posix mode.
167
168 f. Changed here-document processing to process $'...' and $"..." only when they
169 appear in the WORD portion of ${PARAM OP WORD} in the here-document body
170 and the body is being expanded.
171
172 g. Changed alias expansion in command substitution to be posix-conformant
173 (performed while initially parsing the command substitution) when in posix
174 mode.
175
176 h. Bash optimizes away more forks in subshells.
177
178 i. Here-document construction now performs quote removal on the here-document
179 delimiter only if it's marked as quoted, which prevents quote characters in
180 command substitutions from being removed.
181
182 j. Prompt string expansion now gives invisible characters in the expansion of
183 the \w, \W, and \s escape sequences a visible representation to avoid
184 problems with redisplay.
185
186 k. Fixed a problem with SIGINT during the execution of a command bound with
187 `bind -x' affecting the saved terminal settings.
188
189 l. Fixed an inconsistency with how $@ expands in a construct like ${@:+set}
190 or ${array[@]:+set} in the presence of null positional parameters or
191 array elements.
192
193 2. Changes to Readline
194
195 a. Prevent some display problems when running a command as the result of a
196 trap or one bound using `bind -x' and the command generates output.
197
198 b. Fixed an issue with multi-line prompt strings that have one or more
199 invisible characters at the end of a physical line.
200
201 c. Fixed an issue that caused a history line's undo list to be cleared when
202 it should not have been.
203
204 3. New Features in Bash
205
206 a. There is a new bindable readline command name: `vi-edit-and-execute-command'.
207
208 4. New Features in Readline
209
210 a. Two new bindable string variables: active-region-start-color and
211 active-region-end-color. The first sets the color used to display the
212 active region; the second turns it off. If set, these are used in place
213 of terminal standout mode.
214
215 b. New readline state (RL_STATE_EOF) and application-visible variable
216 (rl_eof_found) to allow applications to detect when readline reads EOF
217 before calling the deprep-terminal hook.
218
219 c. There is a new configuration option: --with-shared-termcap-library, which
220 forces linking the shared readline library with the shared termcap (or
221 curses/ncurses/termlib) library so applications don't have to do it.
222
223 ------------------------------------------------------------------------------
224 This document details the changes between this version, bash-5.2-alpha, and
225 the previous version, bash-5.1-release.
226
227 1. Changes to Bash
228
229 a. Fixed a bug that assigned a value to the variable name supplied as an
230 argument to `wait -p' when there were no jobs.
231
232 b. Fixed a bug that resulted in performing incorrect word expansion on the
233 key/value pairs in a compound array assignment.
234
235 c. Fixed a bug that could put the child forked to run a command substitution
236 into the wrong process group.
237
238 d. Fixed a problem that could cause the lastpipe option to work incorrectly if
239 file descriptor 0 was closed.
240
241 e. Bash tries to suppress traps if a forked child receives a trapped signal
242 before it has a chance to reset its signal handlers.
243
244 f. Fixed several memory leaks in compound array assignments.
245
246 g. Fixed a problem with performing an assignment with `+=' to an array element
247 that was the value of a nameref.
248
249 h. Fixed a bug that could cause a nameref containing an array reference using
250 `@' or `*' not to expand to multiple words.
251
252 i. Fixed a bug where extended glob functions could match `.' or `..' when it
253 wasn't explicitly specified, even if dotglob was set.
254
255 j. Fixed a bug that caused non-interactive posix-mode shells not to exit on a
256 variable assignment error while assigning into the temporary environment.
257
258 k. Fixed a bug that caused parsing errors if an alias contained a compound
259 array assignment.
260
261 l. Fixed a couple of instances where bash checked syntax too aggressively when
262 trying to determine how to add a partial command to command-oriented
263 history.
264
265 m. Fixed a parser problem that caused it not to allow reserved words to follow
266 the `((' and `[[' commands.
267
268 n. Fixed a bad offset calculation when using negative offsets to `history -d'.
269
270 o. Fixed an off-by-one error that caused a read past the end of a buffer when
271 reading a multibyte character from the output of a command substitution.
272
273 p. Fixed a problem with a failed `exec' command not setting $? to the right
274 value for an exit trap.
275
276 q. Fixed a problem that caused bash not to unlink FIFOs created as part of
277 expanding redirections for an external command.
278
279 r. Fixed a bug that could cause aliases not to be expanded in case statements.
280
281 s. Fixed a bug that could cause word completion to attempt programmable
282 completion for the target of a redirection, instead of filename completion.
283
284 t. Fixed a bug that could result in errors after rebinding a key sequence with
285 `bind -x' multiple times.
286
287 u. Fixed a problem that could result in not quoting the result when performing
288 command name completion with a glob pattern in the command name.
289
290 v. `mapfile' now uses fully-buffered reads in more cases, which should improve
291 bulk read performance.
292
293 w. Fixed a bug that caused `wait -n' to not reset its internal state when
294 interrupted by a signal, resulting in subsequent calls failing.
295
296 x. Fixed a bug with parsing numeric arguments to readline key sequences
297 installed with `bind -x'.
298
299 y. Bash suppresses forking in several additional cases, including most uses
300 of $(<file).
301
302 z. If there are multiple `!' tokens in a [[ command, toggle the invert state
303 instead of setting it unconditionally.
304
305 aa. Fixed a bug where running `fc' on an empty history list would cause the
306 shell to crash.
307
308 bb. Word completion now checks whether or not a quote character closes a
309 quoted string begun on a previous line, so readline doesn't interpret the
310 quote as starting a new quoted string.
311
312 cc. Fixed a typo that translated \UNNNNNNNN characters that were not valid in
313 the current locale encoding as \uNNNNNNNN.
314
315 dd. Fixed an issue that could cause bash to print timing statistics for the
316 wrong command when `set -e' causes a command to fail.
317
318 ee. Bash now runs the exit trap in function context if a failed command in
319 the function causes the shell to exit.
320
321 ff. Some fixes to how subshells modify $SHLVL.
322
323 gg. Fixed a bug that caused `mapfile -t' not to remove the delimiter when the
324 delimiter is > 128 in the current encoding.
325
326 hh. Fixed a problem that could cause the shell to attempt to free unallocated
327 memory if an expansion error occurred.
328
329 ii. Fixed a bug in the bash malloc implementation of malloc_usable_size. Bash
330 did not use it, but it could cause problems with library functions that
331 did.
332
333 jj. If the `exec' builtin fails, and the shell does not exit, it restores
334 trapped signals to their trapped state.
335
336 kk. Fixed a bug that could cause variable assignment arguments to `declare' to
337 expand variables using attributes that the call to declare was turning off.
338
339 ll. Fixed a bug with LINENO and arithmetic for commands.
340
341 mm. Fixed a posix-mode bug that caused tildes not to be expanded after an
342 unquoted colon on the right side of an assignment statement.
343
344 nn. Fixed a problem with `caller' and line numbers when executing an ERR trap.
345
346 oo. Fixed a problem that could make the value returned by ${a:=b} not be the
347 final value assigned to a (e.g., if `a' has an attribute that modifies
348 the value on assignment).
349
350 pp. Fixed a problem with saving multi-line here-documents to the history list
351 where the here-document delimiter does not appear on the first line.
352
353 qq. Fixed a bug with using += to assign to dynamic variables like RANDOM.
354
355 rr. Fixed a bug that caused `set -n' to modify $? if set after execution had
356 started.
357
358 ss. Builtins like printf/read/wait now behave more consistently when assigning
359 arbitrary keys to associative arrays (like `]'. when appropriately quoted).
360
361 tt. Fixed a problem with here-document collection printing the wrong prompt
362 when parsing a compound list in an interactive shell.
363
364 uu. Fixed a problem with quoting shell expansion characters (like `$') when
365 they appear in a tab-completed word along with characters that do need
366 quoting (e.g.. $HOME/VirtualBox VMs).
367
368 2. Changes to Readline
369
370 a. Fixed a problem with cleaning up active marks when using callback mode.
371
372 b. Fixed a problem with arithmetic comparison operators checking the version.
373
374 c. Fixed a problem that could cause readline not to build on systems without
375 POSIX signal functions.
376
377 d. Fixed a bug that could cause readline to crash if the application removed
378 the callback line handler before readline read all typeahead.
379
380 e. Added additional checks for read errors in the middle of readline commands.
381
382 f. Fixed a redisplay problem that occurred when switching from the digit-
383 argument prompt `(arg: N)' back to the regular prompt and the regular
384 prompt contained invisible characters.
385
386 g. Fixed a problem with restoring the prompt when aborting an incremental
387 search.
388
389 h. Fix a problem with characters > 128 not being displayed correctly in certain
390 single-byte encodings.
391
392 i. Fixed a problem with unix-filename-rubout that caused it to delete too much
393 when applied to a pathname consisting only of one or more slashes.
394
395 j. Fixed a display problem that caused the prompt to be wrapped incorrectly if
396 the screen changed dimensions during a call to readline() and the prompt
397 became longer than the screen width.
398
399 k. Fixed a problem that caused the \r output by turning off bracketed paste
400 to overwrite the line if terminal echo was disabled.
401
402 l. Fixed a bug that could cause colored-completion-prefix to not display if
403 completion-prefix-display-length was set.
404
405 m. Fixed a problem with line wrapping prompts when a group of invisible
406 characters runs to the right edge of the screen and the prompt extends
407 longer then the screen width.
408
409 n. Fixed a couple problems that could cause rl_end to be set incorrectly by
410 transpose-words.
411
412 3. New Features in Bash
413
414 a. The bash malloc returns memory that is aligned on 16-byte boundaries.
415
416 b. There is a new internal timer framework used for read builtin timeouts.
417
418 c. Rewrote the command substitution parsing code to call the parser recursively
419 and rebuild the command string from the parsed command. This allows better
420 syntax checking and catches errors much earlier. Along with this, if
421 command substitution parsing completes with here-documents remaining to be
422 read, the shell prints a warning message and reads the here-document bodies
423 from the current input stream.
424
425 d. The `ulimit' builtin now treats an operand remaining after all of the options
426 and arguments are parsed as an argument to the last command specified by
427 an option. This is for POSIX compatibility.
428
429 e. Here-document parsing now handles $'...' and $"..." quoting when reading the
430 here-document body.
431
432 f. The `shell-expand-line' and `history-and-alias-expand-line' bindable readline
433 commands now understand $'...' and $"..." quoting.
434
435 g. There is a new `spell-correct-word' bindable readline command to perform
436 spelling correction on the current word.
437
438 h. The `unset' builtin now attempts to treat arguments as array subscripts
439 without parsing or expanding the subscript, even when `assoc_expand_once'
440 is not set.
441
442 i. There is a default value for $BASH_LOADABLES_PATH in config-top.h.
443
444 j. Associative array assignment and certain instances of referencing (e.g.,
445 `test -v') now allow `@' and `*' to be used as keys.
446
447 k. Bash attempts to expand indexed and associative array subscripts only
448 once when executing shell constructs and word expansions.
449
450 l. The `unset' builtin allows a subscript of `@' or `*' to unset a key with
451 that value for associative arrays instead of unsetting the entire array
452 (which you can still do with `unset arrayname'). For indexed arrays, it
453 removes all elements of the array without unsetting it (like `A=()').
454
455 m. Additional builtins (printf/test/read/wait) do a better job of not
456 parsing array subscripts if array_expand_once is set.
457
458 n. New READLINE_ARGUMENT variable set to numeric argument for readline commands
459 defined using `bind -x'.
460
461 o. The new `varredir_close' shell option causes bash to automatically close
462 file descriptors opened with {var}<fn and other styles of varassign
463 redirection unless they're arguments to the `exec' builtin.
464
465 p. The `$0' special parameter is now set to the name of the script when running
466 any (non-interactive) startup files such as $BASH_ENV.
467
468 q. The `enable' builtin tries to load a loadable builtin using the default
469 search path if `enable name' (without any options) attempts to enable a
470 non-existent builtin.
471
472 r. The `printf' builtin has a new format specifier: %Q. This acts like %q but
473 applies any specified precision to the original unquoted argument, then
474 quotes and outputs the result.
475
476 s. The new `noexpand_translations' option controls whether or not the translated
477 output of $"..." is single-quoted.
478
479 t. There is a new parameter transformation operator: @k. This is like @K, but
480 expands the result to separate words after word splitting.
481
482 u. There is an alternate array implementation, selectable at `configure' time,
483 that optimizes access speed over memory use (use the new configure
484 --enable-alt-array-implementation option).
485
486 v. If an [N]<&WORD- or [N]>&WORD- redirection has WORD expand to the empty
487 string, treat the redirection as [N]<&- or [N]>&- and close file descriptor
488 N (default 0).
489
490 w. Invalid parameter transformation operators are now invalid word expansions,
491 and so cause fatal errors in non-interactive shells.
492
493 x. New shell option: patsub_replacement. When enabled, a `&' in the replacement
494 string of the pattern substitution expansion is replaced by the portion of
495 the string that matched the pattern. Backslash will escape the `&' and
496 insert a literal `&'.
497
498 y. `command -p' no longer looks in the hash table for the specified command.
499
500 z. The new `--enable-translatable-strings' option to `configure' allows $"..."
501 support to be compiled in or out.
502
503 aa. The new `globskipdots' shell option forces pathname expansion never to
504 return `.' or `..' unless explicitly matched. It is enabled by default.
505
506 bb. Array references using `@' and `*' that are the value of nameref variables
507 (declare -n ref='v[@]' ; echo $ref) no longer cause the shell to exit if
508 set -u is enabled and the array (v) is unset.
509
510 4. New Features in Readline
511
512 a. There is now an HS_HISTORY_VERSION containing the version number of the
513 history library for applications to use.
514
515 b. History expansion better understands multiple history expansions that may
516 contain strings that would ordinarily inhibit history expansion (e.g.,
517 `abc!$!$').
518
519 c. There is a new framework for readline timeouts, including new public
520 functions to set timeouts and query how much time is remaining before a
521 timeout hits, and a hook function that can trigger when readline times
522 out. There is a new state value to indicate a timeout.
523
524 d. Automatically bind termcap key sequences for page-up and page-down to
525 history-search-backward and history-search-forward, respectively.
526
527 e. There is a new `fetch-history' bindable command that retrieves the history
528 entry corresponding to its numeric argument. Negative arguments count back
529 from the end of the history.
530
531 f. `vi-undo' is now a bindable command.
532
533 g. There is a new option: `enable-active-region'. This separates control of
534 the active region and bracketed-paste. It has the same default value as
535 bracketed-paste, and enabling bracketed paste enables the active region.
536 Users can now turn off the active region while leaving bracketed paste
537 enabled.
538
539 h. rl_completer_word_break_characters is now `const char *' like
540 rl_basic_word_break_characters.
541
542 i. Readline looks in $LS_COLORS for a custom filename extension
543 (*.readline-colored-completion-prefix) and uses that as the default color
544 for the common prefix displayed when `colored-completion-prefix' is set.
545
546 ------------------------------------------------------------------------------
547 This document details the changes between this version, bash-5.1-rc3, and
548 the previous version, bash-5.1-rc2.
549
550 1. Changes to Bash
551
552 a. The `assoc_expand_once' option now affects the evaluation of the -v primary
553 to test and the [[ compound command.
554
555 2. Changes to Readline
556
557 a. Fixed a bug that could cause point to be set beyond the end of the line
558 buffer when aborting an incremental search.
559
560 3. New Features in Bash
561
562 4. New Features in Readline
563
564 ------------------------------------------------------------------------------
565 This document details the changes between this version, bash-5.1-rc2, and
566 the previous version, bash-5.1-rc1.
567
568 1. Changes to Bash
569
570 a. Process substitutions started from an interactive shell no longer have their
571 standard input implicitly redirected from /dev/null.
572
573 b. Fixed an issue with setting the SIGINT trap handler in an interactive shell
574 when temporarily running $PROMPT_COMMAND non-interactively.
575
576 2. Changes to Readline
577
578 a. Terminals that are named "dumb" or unknown do not enable bracketed paste
579 by default.
580
581 b. Ensure that disabling bracketed paste turns off highlighting the incremental
582 search string when the search is successful.
583
584 3. New Features in Bash
585
586 4. New Features in Readline
587
588 ------------------------------------------------------------------------------
589 This document details the changes between this version, bash-5.1-rc1, and
590 the previous version, bash-5.1-beta.
591
592 1. Changes to Bash
593
594 a. Fixed an inconsistency in the way HISTCMD is calculated when it's expanded
595 during a multi-line command.
596
597 b. Modified the change to here-document expansion containing backslash-quoted
598 double quotes.
599
600 c. Fixed a case where the shells's exit status could be greater than 255.
601
602 d. Modified changed to process substitution so the executed command has its
603 stdin redirected from /dev/null if it was previously interactive and
604 reading commands from the terminal.
605
606 2. New Features in Bash
607
608 a. There is a new contributed loadable builtin: asort.
609
610 3. Changes to Readline
611
612 a. Fixed a bug that could cause an application with an application-specific
613 redisplay function to crash if the line data structures had not been
614 initialized.
615
616 4. New Features in Readline
617
618 ------------------------------------------------------------------------------
619 This document details the changes between this version, bash-5.1-beta, and
620 the previous version, bash-5.1-alpha.
621
622 1. Changes to Bash
623
624 a. Fixed a bug that caused name references to variables to not update the
625 referenced variable's assignment side effects.
626
627 b. Tightened up the parameter transformation error checking for invalid
628 transformation operators.
629
630 c. System-specific changes for: FreeBSD
631
632 d. A few minor changes to move potential uses of stdio functions out of signal
633 handling paths.
634
635 e. Make sure SIGCHLD is blocked in all cases where waitchld() is not called
636 from a signal handler.
637
638 f. Changed `command' builtin processing so it no longer starts an extra process
639 when run asynchronously (command x &).
640
641 g. Avoid performing tilde expansion after `:' in words that look like assignment
642 statements when in posix mode.
643
644 h. Slight changes to how the `complete' builtin prints out options and actions
645 for completion specifications.
646
647 i. Several changes to how `local -' restores the values of options and
648 $SHELLOPTS.
649
650 j. Don't treat a word in a compound assignment as an assignment statement
651 unless it has a valid subscript before the `='.
652
653 k. Fixed a bug with the DEBUG trap and process substitution that caused the
654 terminal's process group to be set incorrectly.
655
656 l. Fixed a bug that left readline's signal handlers installed while running a
657 shell command from a bindable readline command.
658
659 m. Fixed the `fc' builtin to clamp out of range history specifications at the
660 boundaries of the history list for POSIX conformance.
661
662 n. Fixed a bug that caused ${foo@a} to treat foo as an unset variable if it
663 was an array without a value for subscript 0/"0" but had other set
664 elements.
665
666 o. Fixed a bug that caused the history code to attempt to parse command
667 substitutions looking for shell comments before adding them to the history,
668 even while parsing here-documents.
669
670 p. Fixed a bug that could cause a syntax error in a command read by `eval' to
671 exit an interactive shell.
672
673 2. New Features in Bash
674
675 a. If the hash builtin is listing hashed filenames portably, don't print
676 anything if the table is empty.
677
678 b. GLOBIGNORE now ignores `.' and `..' as a terminal pathname component.
679
680 c. Bash attempts to optimize away forks in the last command in a function body
681 under appropriate circumstances.
682
683 d. The globbing code now uses fnmatch(3) to check collation elements (if
684 available) even in cases without multibyte characters.
685
686 e. The `fg' and `bg' builtins now return an error in a command substitution
687 when asked to restart a job inherited from the parent shell.
688
689 f. The shell now attempts to unlink all FIFOs on exit, whether a consuming
690 process has finished with them or not.
691
692 3. Changes to Readline
693
694 a. Make sure that all undo groups are closed when leaving vi insertion mode.
695
696 b. Make sure that the vi-mode `C' and `c' commands enter insert mode even if
697 the motion command doesn't have any effect.
698
699 c. Fixed several potential memory leaks in the callback mode context handling.
700
701 d. If readline is handling a SIGTTOU, make sure SIGTTOU is blocked while
702 executing the terminal cleanup code, since it's no longer run in a signal
703 handling context.
704
705 4. New Features in Readline
706
707 a. The signal cleanup code now blocks SIGINT while processing after a SIGINT.
708
709 ------------------------------------------------------------------------------
710 This document details the changes between this version, bash-5.1-alpha, and
711 the previous version, bash-5.0-release.
712
713 1. Changes to Bash
714
715 a. Fixed a bug that caused a posix-mode shell to not exit if the return builtin
716 was executed outside a function or dot script.
717
718 b. Fixed a bug where `declare +f' could potentially turn off the function
719 attribute.
720
721 c. Restored bash-4.4 pathname expansion behavior when a word to be expanded had
722 only backslashes, not any of the other globbing characters. This came after
723 an extensive POSIX group discussion (interp #1234).
724
725 d. There are more changes to avoid performing word expansions multiple times on
726 arithmetic expressions.
727
728 e. Fixed a bug with alias expansion when the alias ends with a TAB.
729
730 f. Fixed a bug that caused programmable completion to return an error if the
731 shell function name supplied as an argument to `complete -F' was invalid.
732
733 g. There are several fixes to buffer overflows found as the result of fuzzing
734 with random input.
735
736 h. Fixed a bug that caused the edit-and-execute-command editing command to
737 start with the previous history line if invoked on an empty line.
738
739 i. Fixed a bug that potentially caused `bind --help' to change readline's
740 output stream.
741
742 j. Turning off posix mode now restores the vi-insertion mode binding for TAB
743 that was in effect when posix mode was enabled.
744
745 k. Restore the previous state of job control being enabled if `exec' fails in
746 an interactive shell.
747
748 l. Fixed a bug that caused the terminal's process group to be set incorrectly
749 if job control was turned off before starting an interactive shell.
750
751 m. Fixed a bug that caused a crash when HISTSIZE=0.
752
753 n. Fixed a word expansion bug that caused null strings on the rhs of expansions
754 to be discarded incorrectly.
755
756 o. History list management does a better job of handling the situation where
757 the number of history entries from the current shell session is greater than
758 the number of entries in the history list.
759
760 p. Fixed a bug that caused the `fc' builtin to attempt to dereference a newly-
761 freed history entry.
762
763 q. Fixed a bug that made the `Q' variable transformation not work well with
764 `set -u'.
765
766 r. There are several word expansion fixes for expanding $* and $@ in contexts
767 where word splitting is not going to be performed, since each positional
768 parameter must expand to a separate word.
769
770 s. Fixed a bug that could cause ^D to exit bash immediately even if there were
771 stopped jobs.
772
773 t. Fixed a bug with double-quoting and backslash-quoting strings containing
774 multibyte characters for reuse.
775
776 u. Fixed a bug that caused the line number to be reported incorrectly if the
777 shell executed a (command) subshell.
778
779 v. Fixed a bug that caused the shell to fail to reap process substitutions
780 when they went out of scope, which had unpredictable results.
781
782 w. Fixed a bug that caused null strings in arguments to [[ conditional command
783 operators to compare incorrectly.
784
785 x. Changed the behavior of `wait' without arguments to only wait for background
786 processes the current shell instance started, not background children it may
787 have inherited.
788
789 y. Fixed a bug that could cause command substitution to leave file descriptors
790 open if the shell received many SIGINTs.
791
792 z. Bash now behaves better if the `**' filename expansion operator encounters a
793 symbolic link to a directory, avoiding more cases where it might return
794 duplicate pathnames.
795
796 aa. Programmable completion now canonicalizes directory names in the same way
797 as bash word completion, so `..' is handled consistently.
798
799 bb. Fixed a bug when using RETURN as the delimiter to the read builtin; it
800 caused readline to set the binding for RETURN incorrectly.
801
802 cc. Fixed a bug that caused `history -d' to delay printing an out-of-range
803 error message.
804
805 dd. Fixed a bug with `bash -c command' where `command' ends with an expanded
806 alias.
807
808 ee. Fixed a bug that could result in `history -n' adding spurious line feeds to
809 commands in the history list.
810
811 ff. The $RANDOM random number generator now XORs the top and bottom halves of
812 the internal 32-bit value to introduce more randomness. Setting the shell
813 compatibility level to 50 or lower undoes this.
814
815 gg. Fixed several problems caused by running the DEBUG trap on simple commands
816 executed as part of a pipeline.
817
818 ii. Fixed a bug that didn't allow `bind -r' to remove the binding for \C-@.
819
820 jj. Several fixes to the bash-backward-shellword bindable readline command to
821 behave better when at the last character on the line.
822
823 kk. If `set -x' is enabled, bash doesn't print a command twice if it's run by
824 the `command' builtin.
825
826 ll. Fixed a bug with printing function definitions containing here documents.
827
828 mm. Fixed a bug that could cause the `bind' builtin to set $? to -1.
829
830 nn. Fixed a bug that didn't reset the timezone information correctly when the
831 TZ variable was unset.
832
833 oo. Fixed several issues with assigning an associative array variable using a
834 compound assignment that expands the value of the same variable.
835
836 pp. Fixed several places where the shell set $? without setting PIPESTATUS.
837
838 qq. Fixed a problem with glob bracket expressions containing invalid character
839 classes, collating symbols, or equivalence classes -- they should not
840 require a closing right bracket.
841
842 rr. Fixed a bug where running a builtin in a subshell did not run the EXIT trap.
843
844 ss. Fixed several problems with posix-mode variable assignments preceding
845 shell function calls and posix special builtins, so that they create and
846 modify variables at the current scope.
847
848 tt. Fix history initialization so `bash +o history' works as expected.
849
850 uu. Fixed a bug in the bindable edit-and-execute-command command that could
851 interfere with the shell's parsing state.
852
853 vv. Fixed an issue with nested traps running command substitutions in command
854 lines with command substitutions.
855
856 ww. Fixed a bug with globbing pathnames that contain invalid multibyte
857 characters (sequences that don't correspond to a character in the current
858 locale).
859
860 xx. Fixed a bug that caused the shell not to exit if a function definition
861 failed while errexit was enabled.
862
863 yy. Process substitution processes now get their input from /dev/null, since
864 they are asynchronous, not interactive, and not jobs.
865
866 zz. Setting nocaseglob no longer turns on case-insensitive regexp matching.
867
868 aaa. Fixed a bug that resulted in extra blank lines being added to some history
869 entries containing here-documents.
870
871 bbb. Fixed a bug that resulted in incorrect matching of some patterns in word
872 expansion if they expanded to the empty string.
873
874 ccc. Fixed here-string expansion so it behaves the same as expansion of the
875 rhs of an assignment statement.
876
877 ddd. Changed here-document parsing to no longer allow the end of the here
878 document to delimit a command substitution.
879
880 eee. Several fixes to history expansion: multiple :p modifiers work, a ^ word
881 designator works as part of a range, and a `-' is treated as part of a
882 search string if it immediately follows a `!'.
883
884 fff. Fixed a bug in pattern substitution with null matches in a string
885 containing multibyte characters.
886
887 ggg. Unbinding a key sequence bound with `bind -x' now removes the key sequence
888 from the additional keymap `bind -x' uses.
889
890 hhh. Fixed a bug with command start detection for completion so that it doesn't
891 mistake brace expansion for the start of a command.
892
893 iii. Fixed a bug that caused local variables with the same name as variables
894 appearing in a function's temporary environment to not be marked as local.
895
896 jjj. Fixed a bug that could cause SIGCHLD to be blocked when executing return
897 or exec in the rightmost pipeline element with lastpipe enabled.
898
899 kkk. Fixed a bug that could result in commands without the execute bit set
900 being added to the command hash table.
901
902 lll. Fixed a bug that allowed non-digits to follow the `#' in a `base#number'
903 integer constant.
904
905 mmm. Fixed a bug that made `time -- command' attempt to execute `--'.
906
907 nnn. Fixed a couple of bugs with variable transformation using arrays
908 subscripted with `*' or `@'.
909
910 ooo. A failure to create a variable using `declare' in a function no longer
911 causes the function to return immediately.
912
913 ppp. Fixed a bug that could cause the := word expansion to add a non-null
914 value if attempting to assign a null string when double-quoted.
915
916 qqq. Fixed a bug that could cause backslashes quoting double quotes in here
917 document bodies to not be removed when expanding the body.
918
919 rrr. Fixed a bug that caused commands following a subshell while the shell is
920 reading input from stdin but not interactive, while job control is
921 enabled, to be executed twice.
922
923 sss. Fixed a bug where receiving SIGTERM from a different process while
924 readline was active could cause the shell to terminate.
925
926 ttt. In posix mode, running a trap after the read builtin now sees the exit
927 status of the read builtin (e.g., 130 after a SIGINT) in $?.
928
929 uuu. Fixed a bug with nameref variables referencing array subscripts used in
930 arithmetic expressions.
931
932 vvv. Fixed a bug that caused the pipeline process group id to be reset in the
933 middle of a command list run by a shell started to run a command
934 substitution.
935
936 www. Restricted shells can no longer read and write history files with pathnames
937 containing slashes.
938
939 xxx. Fixed a couple of problems with 0 and -0 used as arguments to `fc' when
940 not listing commands from the history.
941
942 yyy. When `test' is supplied four or more arguments, treat an argument that
943 looks like an operator (e.g., -e), but is in a place where only a string
944 is valid, as a string, as it would be when using the POSIX rules, instead
945 of an operator with a missing argument.
946
947 zzz. There is no `compat50' shopt option. Changes to the shell compatibility
948 level should use the BASH_COMPAT variable.
949
950 aaaa. Redirection failures with compound commands are now treated as errors
951 that cause the shell to exit if `errexit' is enabled.
952
953 bbbb. Redirection failure error messages no longer expand the word in the
954 redirection again.
955
956 cccc. History expansion is no longer performed while parsing a here-document
957 inside a command substitution.
958
959 2. Changes to Readline
960
961 a. There are a number of fixes that were found as the result of fuzzing with
962 random input.
963
964 b. Changed the revert-all-at-newline behavior to make sure to start at the end
965 of the history list when doing it, instead of the line where the user hit
966 return.
967
968 c. When parsing `set' commands from the inputrc file or an application, readline
969 now allows trailing whitespace.
970
971 d. Fixed a bug that left a file descriptor open to the history file if the
972 file size was 0.
973
974 e. Fixed a problem with binding key sequences containing meta characters.
975
976 f. Fixed a bug that caused the wrong line to be displayed if the user tried to
977 move back beyond the beginning of the history list, or forward past the end
978 of the history list.
979
980 g. If readline catches SIGTSTP, it now sets a hook that allows the calling
981 application to handle it if it desires.
982
983 h. Fixed a redisplay problem with a prompt string containing embedded newlines.
984
985 i. Fixed a problem with completing filenames containing invalid multibyte
986 sequences when case-insensitive comparisons are enabled.
987
988 j. Fixed a redisplay problem with prompt strings containing invisible multibyte
989 characters.
990
991 k. Fixed a problem with multibyte characters mapped to editing commands that
992 modify the search string in incremental search.
993
994 l. Fixed a bug with maintaining the key sequence while resolving a bound
995 command in the presence of ambiguous sequences (sequences with a common
996 prefix), in most cases while attempting to unbind it.
997
998 m. Fixed several buffer overflows found as the result of fuzzing.
999
1000 n. Reworked backslash handling when translating key sequences for key binding
1001 to be more uniform and consistent, which introduces a slight backwards
1002 incompatibility.
1003
1004 o. Fixed a bug with saving the history that resulted in errors not being
1005 propagated to the calling application when the history file is not writable.
1006
1007 p. Readline only calls chown(2) on a newly-written history file if it really
1008 needs to, instead of having it be a no-op.
1009
1010 q. Readline now behaves better when operate-and-get-next is used when the
1011 history list is `full': when there are already $HISTSIZE entries.
1012
1013 r. Fixed a bug that could cause vi redo (`.') of a replace command not to work
1014 correctly in the C or POSIX locale.
1015
1016 s. Fixed a bug with vi-mode digit arguments that caused the last command to be
1017 set incorrectly. This prevents yank-last-arg from working as intended, for
1018 example.
1019
1020 3. New Features in Bash
1021
1022 a. `bind -x' now supports different bindings for different editing modes and
1023 keymaps.
1024
1025 b. Bash attempts to optimize the number of times it forks when executing
1026 commands in subshells and from `bash -c'.
1027
1028 c. Here documents and here strings now use pipes for the expanded document if
1029 it's smaller than the pipe buffer size, reverting to temporary files if it's
1030 larger.
1031
1032 d. There are new loadable builtins: mktemp, accept, mkfifo, csv, cut/lcut
1033
1034 e. In posix mode, `trap -p' now displays signals whose disposition is SIG_DFL
1035 and those that were SIG_IGN when the shell starts.
1036
1037 f. The shell now expands the history number (e.g., in PS1) even if it is not
1038 currently saving commands to the history list.
1039
1040 g. `read -e' may now be used with arbitrary file descriptors (`read -u N').
1041
1042 h. The `select' builtin now runs traps if its internal call to the read builtin
1043 is interrupted by a signal.
1044
1045 i. SRANDOM: a new variable that expands to a 32-bit random number that is not
1046 produced by an LCRNG, and uses getrandom/getentropy, falling back to
1047 /dev/urandom or arc4random if available. There is a fallback generator if
1048 none of these are available.
1049
1050 j. shell-transpose-words: a new bindable readline command that uses the same
1051 definition of word as shell-forward-word, etc.
1052
1053 k. The shell now adds default bindings for shell-forward-word,
1054 shell-backward-word, shell-transpose-words, and shell-kill-word.
1055
1056 l. Bash now allows ARGV0 appearing in the initial shell environment to set $0.
1057
1058 m. If `unset' is executed without option arguments, bash tries to unset a shell
1059 function if a name argument cannot be a shell variable name because it's not
1060 an identifier.
1061
1062 n. The `test -N' operator uses nanosecond timestamp granularity if it's
1063 available.
1064
1065 o. Bash posix mode now treats assignment statements preceding shell function
1066 definitions the same as in its default mode, since POSIX has changed and
1067 no longer requires those assignments to persist after the function returns
1068 (POSIX interp 654).
1069
1070 p. BASH_REMATCH is no longer readonly.
1071
1072 q. wait: has a new -p VARNAME option, which stores the PID returned by `wait -n'
1073 or `wait' without arguments.
1074
1075 r. Sorting the results of pathname expansion now uses byte-by-byte comparisons
1076 if two strings collate equally to impose a total order; the result of a
1077 POSIX interpretation (#963 and #1070).
1078
1079 s. Bash now allows SIGINT trap handlers to execute recursively.
1080
1081 t. Bash now saves and restores state around setting and unsetting posix mode,
1082 instead of having unsetting posix mode set a known state.
1083
1084 u. Process substitution is now available in posix mode.
1085
1086 v. READLINE_MARK: a new variable available while executing commands bound with
1087 `bind -x', contains the value of the mark.
1088
1089 w. Bash removes SIGCHLD from the set of blocked signals if it's blocked at shell
1090 startup.
1091
1092 x. `test -v N' can now test whether or not positional parameter N is set.
1093
1094 y. `local' now honors the `-p' option to display all local variables at the
1095 current context.
1096
1097 z. The `@a' variable transformation now prints attributes for unset array
1098 variables.
1099
1100 aa. The `@A' variable transformation now prints a declare command that sets a
1101 variable's attributes if the variable has attributes but is unset.
1102
1103 bb. `declare' and `local' now have a -I option that inherits attributes and
1104 value from a variable with the same name at a previous scope.
1105
1106 cc. When run from a -c command, `jobs' now reports the status of completed jobs.
1107
1108 dd. New `U', `u', and `L' parameter transformations to convert to uppercase,
1109 convert first character to uppercase, and convert to lowercase,
1110 respectively.
1111
1112 ee. PROMPT_COMMAND: can now be an array variable, each element of which can
1113 contain a command to be executed like a string PROMPT_COMMAND variable.
1114
1115 ff. `ulimit' has a -R option to report and set the RLIMIT_RTTIME resource.
1116
1117 gg. Associative arrays may be assigned using a list of key-value pairs within
1118 a compound assignment. Compound assignments where the words are not of
1119 the form [key]=value are assumed to be key-value assignments. A missing or
1120 empty key is an error; a missing value is treated as NULL. Assignments may
1121 not mix the two forms.
1122
1123 hh. New `K' parameter transformation to display associative arrays as key-
1124 value pairs.
1125
1126 ii. Writing history to syslog now handles messages longer than the syslog max
1127 length by writing multiple messages with a sequence number.
1128
1129 jj. SECONDS and RANDOM may now be assigned using arithmetic expressions, since
1130 they are nominally integer variables. LINENO is not an integer variable.
1131
1132 kk. Bash temporarily suppresses the verbose option when running the DEBUG trap
1133 while running a command from the `fc' builtin.
1134
1135 ll. `wait -n' now accepts a list of job specifications as arguments and will
1136 wait for the first one in the list to change state.
1137
1138 mm. The associative array implementation can now dynamically increase the
1139 size of the hash table based on insertion patterns.
1140
1141 nn. HISTFILE is now readonly in a restricted shell.
1142
1143 oo. The bash malloc now returns memory that is 16-byte aligned on 64-bit
1144 systems.
1145
1146 4. New Features in Readline
1147
1148 a. If a second consecutive completion attempt produces matches where the first
1149 did not, treat it as a new completion attempt and insert a match as
1150 appropriate.
1151
1152 b. Bracketed paste mode works in more places: incremental search strings, vi
1153 overstrike mode, character search, and reading numeric arguments.
1154
1155 c. Readline automatically switches to horizontal scrolling if the terminal has
1156 only one line.
1157
1158 d. Unbinding all key sequences bound to a particular readline function now
1159 descends into keymaps for multi-key sequences.
1160
1161 e. rl-clear-display: new bindable command that clears the screen and, if
1162 possible, the scrollback buffer (bound to emacs mode M-C-l by default).
1163
1164 f. New active mark and face feature: when enabled, it will highlight the text
1165 inserted by a bracketed paste (the `active region') and the text found by
1166 incremental and non-incremental history searches. This is tied to bracketed
1167 paste and can be disabled by turning off bracketed paste.
1168
1169 g. Readline sets the mark in several additional commands.
1170
1171 h. Bracketed paste mode is enabled by default.
1172
1173 i. Readline tries to take advantage of the more regular structure of UTF-8
1174 characters to identify the beginning and end of characters when moving
1175 through the line buffer.
1176
1177 j. The bindable operate-and-get-next command (and its default bindings) are
1178 now part of readline instead of a bash-specific addition.
1179
1180 ------------------------------------------------------------------------------
1181 This document details the changes between this version, bash-5.0-release, and
1182 the previous version, bash-5.0-rc1.
1183
1184 1. Changes to Bash
1185
1186 a. Tilde expansion isn't performed on indexed array subscripts, even for
1187 backwards compatibility.
1188
1189 b. The shell doesn't exit in posix mode if the eval builtin gets a parse
1190 error when run by the command builtin.
1191
1192 c. Fixed a bug that caused a shell comment in an alias to not find the end
1193 of the alias properly.
1194
1195 d. Reverted a change from April, 2018 that caused strings containing
1196 backslashes to be flagged as glob patterns.
1197
1198 2. Changes to Readline
1199
1200 3. New Features in Bash
1201
1202 4. New Features in Readline
1203
1204 ------------------------------------------------------------------------------
1205 This document details the changes between this version, bash-5.0-rc1, and
1206 the previous version, bash-5.0-beta2.
1207
1208 1. Changes to Bash
1209
1210 a. Fix to initial word completion detection code.
1211
1212 b. Fixed a bug that caused issues with assignment statements containing ^A in
1213 the value assigned when IFS contains ^A.
1214
1215 c. Added a fallback to fnmatch() when strcoll can't correctly deal with
1216 bracket expression character equivalence classes.
1217
1218 d. Fixed a bug that caused $BASH_COMMAND to contain the trap handler command
1219 when running a trap handler containing [[ or (( commands.
1220
1221 e. Fixed a bug that caused nameref assignments in the temporary environment
1222 to potentially create variables with invalid names.
1223
1224 f. Fixed a bug that caused `local -' to turn off alias expansion in scripts.
1225
1226 g. Fixed a parser issue with a command string containing EOF after an invalid
1227 command as an argument to a special builtin not causing a posix-mode shell
1228 to exit.
1229
1230 h. Made a slight change to the FNV-1 string hash algorithm used for associative
1231 arrays (corrected the initial seed).
1232
1233 2. Changes to Readline
1234
1235 3. New Features in Bash
1236
1237 a. The `select' command now supports command forms without a word list
1238 following `in'.
1239
1240 4. New Features in Readline
1241
1242 ------------------------------------------------------------------------------
1243 This document details the changes between this version, bash-5.0-beta2, and
1244 the previous version, bash-5.0-beta.
1245
1246 1. Changes to Bash
1247
1248 a. Fixed a bug that could cause a seg fault while parsing a subshell command
1249 inside a command substitution.
1250
1251 b. Fixed several small memory leaks uncovered by coverity.
1252
1253 c. Fixed a problem with command substitution inside an interactive shell that
1254 could cause the parent to receive a SIGHUP.
1255
1256 d. Fixed a problem with using `*' and `@' as subscripts when assigning values
1257 to an associative array with assoc_expand_once enabled.
1258
1259 e. Fixed a bug that could cause a huge memory allocation when completing a
1260 word beginning with an invalid tilde expansion.
1261
1262 f. Cleaned up some incompatibilities with bash-4.4 when expanding indexed array
1263 subscripts used in arithmetic expansions when assoc_expand_once is enabled.
1264
1265 g. The ${parameter@a} expansion will display attributes even if `parameter' is
1266 unset.
1267
1268 h. Fixed a bug that caused the output of `set' to cut off some variables before
1269 printing the value.
1270
1271 i. Treat a failure to assign a variable when using the ${x:=value} expansion
1272 as an expansion error, so non-interactive posix-mode shells exit
1273
1274 j. Fixed a problem when expanding $* in a context where word splitting is not
1275 performed when IFS is NULL.
1276
1277 k. Temp files used to store here documents are forced readable, no matter what
1278 the user's umask says.
1279
1280 l. Fixed a problem where an interrupted brace expansion could cause the shell
1281 to attempt to free an invalid memory location.
1282
1283 m. Make sure to check for any terminating signals after running a trap
1284 handler; don't wait until the next time we process traps.
1285
1286 n. Fixed a bug that caused "return" to act like a special builtin with respect
1287 to variable assignments even when preceded by "command".
1288
1289 o. POSIX-mode shells now return failure if the cd builtin fails due to the
1290 absolute directory name being longer than PATH_MAX, instead of trying
1291 again with a relative pathname.
1292
1293 p. Fixed a problem with FUNCNAME occasionally being visible when not executing
1294 a shell function.
1295
1296 q. Fixed a problem with the expansions performed on the WORD in the case
1297 command.
1298
1299 r. Fixed a slight POSIX compatibility when removing "IFS whitespace" during
1300 word splitting and the read builtin.
1301
1302 s. Fixed a problem with expanding an array with subscript `*' when all the
1303 elements expand to the empty string, and making sure the expansion honors
1304 the `:' specifier.
1305
1306 2. Changes to Readline
1307
1308 a. Fixed a bug with adding multibyte characters to an incremental search string.
1309
1310 b. Fixed a bug with redoing text insertions in vi mode.
1311
1312 c. Fixed a bug with pasting text into an incremental search string if bracketed
1313 paste mode is enabled. ESC cannot be one of the incremental search
1314 terminator characters for this to work.
1315
1316 d. Fixed a bug with anchored search patterns when performing searches in vi
1317 mode.
1318
1319 3. New Features in Bash
1320
1321 a. Associative and indexed arrays now allow subscripts consisting solely of
1322 whitespace.
1323
1324 b. `checkwinsize' is now enabled by default.
1325
1326 c. The `localvar_unset' shopt option is now visible and documented.
1327
1328 d. The `progcomp_alias' shopt option is now visible and documented.
1329
1330 e. The signal name processing code now understands `SIGRTMIN+n' all the way
1331 up to SIGRTMAX.
1332
1333 f. There is a new `seq' loadable builtin.
1334
1335 g. Trap execution now honors the (internal) max invocations of `eval', since
1336 traps are supposed to be executed as if using `eval'.
1337
1338 h. The $_ variable doesn't change when the shell executes a command that forks.
1339
1340 i. The `kill' builtin now supports -sSIGNAME and -nSIGNUM, even though
1341 conforming applications aren't supposed to use them.
1342
1343 j. POSIX mode now enables the `shift_verbose' option.
1344
1345 4. New Features in Readline
1346
1347 a. Readline now allows application-defined keymap names; there is a new public
1348 function, rl_set_keymap_name(), to do that.
1349
1350 b. The "Insert" keypad key, if available, now puts readline into overwrite
1351 mode.
1352
1353 ------------------------------------------------------------------------------
1354 This document details the changes between this version, bash-5.0-beta, and
1355 the previous version, bash-5.0-alpha.
1356
1357 1. Changes to Bash
1358
1359 a. Fixed a bug that allowed subshells to "inherit" enclosing loops -- this
1360 is where POSIX says the subshell is not "enclosed" by the loop.
1361
1362 b. Added more UTF-8-specific versions of multibyte functions, and optimized
1363 existing functions if the current locale uses UTF-8 encoding.
1364
1365 c. In POSIX mode, assignments preceding regular builtins should not persist
1366 when the builtin completes.
1367
1368 d. Added additional checks to special array assignment (e.g., BASH_ALIASES)
1369 so it can't be used to bypass validity checks performed in other places.
1370
1371 e. The `!!' history expansion now refers to the previous history entry as
1372 expected, even if used on the second or subsequent line of a multi-line
1373 history entry.
1374
1375 f. Fixed a bug that could cause the shell to dereference a NULL pointer if
1376 the environment (`environ') is set to NULL.
1377
1378 g. Bash uses slightly better integer overflow handling for brace sequence
1379 expansion on systems where ints are 32 bits and intmax_t is 64 bits.
1380
1381 h. Fixed a bug setting attributes for a variable named as an argument to
1382 `declare' that also appears as a nameref in the temporary environment.
1383
1384 i. Fixed several bugs that could cause assignments to namerefs to create
1385 variables with invalid names.
1386
1387 j. Fixed a bug that could result in the SIGINT handler being set incorrectly
1388 in asynchronous subshells.
1389
1390 k. Fixed a bug that could cause `bash -t' to not execute the specified command.
1391
1392 l. Fixed several bugs that caused the shell to operate on the wrong variable
1393 when using namerefs with the same name as a global variable in shell
1394 functions.
1395
1396 m. Internal changes to how the shell handles variables with invalid names in
1397 the initial environment and to prevent variables with invalid names from
1398 being added to the environment instead of passing them on to children.
1399
1400 n. Changes to make sure that an expansion that results in a quoted null string
1401 is reflected in the expansion, even if the word expands to nothing.
1402
1403 o. Changes to make sure that $* and ${array[*]} (and $@/${array[@]}) expand
1404 the same way after the recent changes for POSIX interpretation 888.
1405
1406 p. Saving and restoring the positional parameters at function entry and exit
1407 is considerably more efficient; noticeably so when there are large numbers
1408 of positional parameters.
1409
1410 q. Fixed a bug that caused `lastpipe' and `pipefail' to return an incorrect
1411 status for the pipeline if there was more than one external command in a
1412 loop body appearing in the last pipeline element.
1413
1414 r. Fixed a bug that caused value conversion errors with the printf builtin's
1415 %u and %f conversion specifications and invalid constants.
1416
1417 2. Changes to Readline
1418
1419 a. Added more UTF-8-specific versions of multibyte functions, and optimized
1420 existing functions if the current locale uses UTF-8 encoding.
1421
1422 b. Fixed a problem with bracketed-paste inserting more than one character and
1423 interacting with other readline functions.
1424
1425 c. Fixed a bug that caused the history library to attempt to append a history
1426 line to a non-existent history entry.
1427
1428 d. If using bracketed paste mode, output a newline after the \r that is the
1429 last character of the mode disable string to avoid overwriting output.
1430
1431 e. Fixes to the vi-mode `b', `B', `w', `W', `e', and `E' commands to better
1432 handle multibyte characters.
1433
1434 f. Fixed a redisplay problem that caused an extra newline to be generated on
1435 accept-line when the line length is exactly the screenwidth.
1436
1437 3. New Features in Bash
1438
1439 a. Bash no longer allows variable assignments preceding a special builtin that
1440 changes variable attributes to propagate back to the calling environment
1441 unless the compatibility level is 44 or lower.
1442
1443 b. You can set the default value for $HISTSIZE at build time in config-top.h.
1444
1445 c. The `complete' builtin now accepts a -I option that applies the completion
1446 to the initial word on the line.
1447
1448 d. The internal bash malloc now uses mmap (if available) to satisfy requests
1449 greater than 128K bytes, so free can use mfree to return the pages to the
1450 kernel.
1451
1452 e. The shell doesn't automatically set BASH_ARGC and BASH_ARGV at startup
1453 unless it's in debugging mode, as the documentation has always said, but
1454 will dynamically create them if a script references them at the top level
1455 without having enabled debugging mode.
1456
1457 f. The localvar_inherit option will not attempt to inherit a value from a
1458 variable of an incompatible type (indexed vs. associative arrays, for
1459 example).
1460
1461 g. The `globasciiranges' option is now enabled by default; it can be set to
1462 off by default at configuration time.
1463
1464 4. New Features in Readline
1465
1466 a. The history expansion library now understands command and process
1467 substitution and extended globbing and allows them to appear anywhere in a
1468 word.
1469
1470 b. The history library has a new variable that allows applications to set the
1471 initial quoting state, so quoting state can be inherited from a previous
1472 line.
1473
1474 ------------------------------------------------------------------------------
1475 This document details the changes between this version, bash-5.0-alpha, and
1476 the previous version, bash-4.4-release.
1477
1478 1. Changes to Bash
1479
1480 a. Fixed a bug that could cause traps in background jobs to give the terminal
1481 to the wrong process group.
1482
1483 b. Fixed a bug that caused `kill -l 0' to print an out-of-range error.
1484
1485 c. Fixed a problem that could result in here-documents being displayed in
1486 the wrong order.
1487
1488 d. Fixed a number of out-of-bounds and free memory read errors found via
1489 fuzzing.
1490
1491 e. Fixed a subshell inheritance problem that could cause a subshell to wait for
1492 the wrong process.
1493
1494 f. Fixed a bug that caused SHLVL to be incremented one too many times when
1495 creating subshells.
1496
1497 g. A job dying due to SIGINT can now interrupt sourcing a file in a shell with
1498 job control enabled.
1499
1500 h. Fixed a spurious warning about unterminated ${ or $( constructs during
1501 word completion.
1502
1503 i. The shell no longer runs traps if a signal arrives while reading command
1504 substitution output.
1505
1506 j. Fixed an arithmetic expansion error that could allow ++var++ as valid
1507 syntax.
1508
1509 k. Fixed an error that allowed out-of-bounds references to the directory stack.
1510
1511 l. The shell does a better job of saving multi-line history entries with
1512 embedded comments.
1513
1514 m. Fixed a bug that could cause quoted bracket expressions in regular expression
1515 arguments to `[[' to not match correctly.
1516
1517 n. Fixed a bug that could cause an IFS character in a word to result in an
1518 extra '\001' character in the expansion.
1519
1520 o. A trailing backslash in a glob pattern can match a trailing backslash in the
1521 string.
1522
1523 p. Fixed a memory leak in the process creation code path when job control is
1524 enabled.
1525
1526 q. Fixed a bug that caused `printf' to output broken surrogate pairs for
1527 Japanese locales.
1528
1529 r. Fixed a bug that caused a SIGINT generated from `kill' in a dot script to
1530 kill an interactive shell.
1531
1532 s. Fixed a bug that could cause the `read' builtin to not fully read a
1533 multibyte character.
1534
1535 t. Fixed a bug that could cause identifiers to be evaluated in conditional
1536 arithmetic expressions even when evaluation is suppressed.
1537
1538 u. Fixed a bug that could result in command substitution, when executed in a
1539 context where word splitting is not performed, to leave a stray '\001'
1540 character in the string.
1541
1542 v. Fixed a bug that could cause history expansion to be disabled in a non-
1543 interactive shell even if `-o histexpand' is supplied at startup.
1544
1545 w. Fixed a bug that caused `read -N' to strip leading whitespace IFS characters.
1546
1547 x. Fixed a bug that caused spurious tilde expansion in arithmetic expressions.
1548
1549 y. If indirect expansion attempts to indirectly reference through an unset
1550 variable, report an error.
1551
1552 z. Added a guard to prevent the shell from looping while receiving an endless
1553 stream of SIGTTIN at shell startup.
1554
1555 aa. Fixed a bug with parsing here documents inside a command substitution when
1556 looking for the closing delimiter.
1557
1558 bb. Fixed a bug that caused printf to not quote all <blank> characters in the
1559 current locale when using the `%q' format specifier.
1560
1561 cc. Fixed a bug with bash's internal buffered I/O system that caused the input
1562 pointer to not be reset when read(2) returned an EOF.
1563
1564 dd. Bash now installs its SIGWINCH signal handler with SA_RESTART, so it will
1565 not interrupt open/read/write system calls.
1566
1567 ee. The ERR trap now reports line numbers more reliably.
1568
1569 ff. The shell no longer tries to manipulate the terminal process group if a
1570 command or process substitution is killed by SIGTERM when job control is
1571 enabled.
1572
1573 gg. Fixed a bug that caused extglob patterns to match filenames beginning with
1574 a period.
1575
1576 hh. File descriptors open for writing to here documents are no longer available
1577 to subshells.
1578
1579 ii. Make sure word completion doesn't perform command or process substitution.
1580
1581 jj. Fixed a bug with parsing $$'...' inside a command substitution.
1582
1583 kk. Fixed a bug that caused bash to remove backslash-newline pairs from the
1584 body of a here-document with a quoted delimiter inside a command
1585 substitution.
1586
1587 ll. Fixed a bug that could cause the shell to hang when adding a pid to the
1588 table of background process exit statuses.
1589
1590 mm. Fixed a bug that could cause 0x01 characters to be doubled in the output
1591 of process substitution.
1592
1593 nn. Restricted shells now clear the hash table before making the PATH variable
1594 read-only.
1595
1596 oo. There are a number of changes to the expansion of $* and $@ in contexts
1597 where word splitting does not occur (quoted and unquoted), with IFS set
1598 to NULL or a non-standard value, mostly to deal with the consequences of
1599 the behavior defined in Posix interpretation 888.
1600
1601 pp. There are a number of changes to nameref variable handling to avoid
1602 creating variables with invalid names.
1603
1604 qq. A non-interactive posix mode shell no longer exits when an assignment
1605 statement fails if the assignment is utimately being performed by the
1606 `command' builtin.
1607
1608 rr. When using character class names for globbing, don't allow case
1609 insensitivity, even if nocaseglob is enabled.
1610
1611 ss. Fixed a bug that allowed some redirections to stay in place if a later
1612 redirection failed.
1613
1614 tt. Fixed a bug in how command and process substitutions are recognized within
1615 other parameter expansions.
1616
1617 uu. Fixed a bug that caused bash to loop under certain circumstances when
1618 performing arithmetic expansion on a variable whose value is an invalid
1619 expression.
1620
1621 vv. Fixed a bug that could cause bash to expand aliases inappropriately while
1622 parsing compound commands like `case'.
1623
1624 ww. Fixed a bug that could cause `read -N' to fail to read complete multibyte
1625 characters, even when the sequences are incomplete or invalid, with or
1626 without readline.
1627
1628 xx. Fixed a bug that could cause `case' to fail to match patterns containing
1629 0x01 characters.
1630
1631 yy. Fixed a bug that caused exported functions to contain stray 0x01 characters.
1632
1633 zz. Fixed some inconsistencies with how the history number is handled in the
1634 various prompt strings.
1635
1636 aaa. Fixed a bug that could cause a core dump if READLINE_LINE was unset
1637 inside a shell function bound to a key sequence with `bind -x'.
1638
1639 bbb. Fixed a bug that could cause bash to not read a token terminator correctly
1640 if a command substitution was used inside an arithmetic `for' command.
1641
1642 ccc. Fixed problems that could occur with a fatal arithmetic expansion error
1643 in a context (like prompt expansion) where you can't jump back to the
1644 top level.
1645
1646 ddd. Expression errors in arithmetic `for' commands are treated more like
1647 shell syntax errors.
1648
1649 eee. Fixed a parser synchronization error resulting from a syntax error
1650 followed immediately by an EOF.
1651
1652 fff. When executing a shell function, the first line in the function ($LINENO)
1653 is line 1 instead of line 0, as Posix requires.
1654
1655 ggg. In Posix mode, bash will canonicalize the value of PWD it inherits from
1656 the environment and use that to set its idea of the current directory.
1657
1658 hhh. If LINENO is exported, bash needs to regenerate its value each time it
1659 constructs the environment.
1660
1661 iii. Fixed a bug with restoring the SIGINT handler when using `wait -n'.
1662
1663 jjj. Make sure the `coproc' command returns an appropriate status if the NAME
1664 argument is invalid.
1665
1666 kkk. Fixed a problem with arithmetic expressions containing array references
1667 that contain arithmetic expressions with syntax errors.
1668
1669 lll. The `select' command and help builtin will use $COLUMNS before the window
1670 size returned from the kernel as the terminal width.
1671
1672 mmm. `read -n 0' and `read -N 0' now try a zero-length read in an attempt to
1673 detect file descriptor errors.
1674
1675 nnn. The `read' builtin now does a better job of acting on signals that don't
1676 interrupt read(2).
1677
1678 ooo. Fixed some cases where `printf -v' did not return failure status on a
1679 variable assignment error.
1680
1681 ppp. Fixed temporary environment propagation back to the current environment
1682 so that it doesn't happen for special builtins run by the `command'
1683 builtin.
1684
1685 qqq. Fixed a bug when searching for the end of a here-document delimiter in a
1686 command substitution.
1687
1688 rrr. Fixed a bug that could cause `cd ${DIRSTACK[0]}' to fail.
1689
1690 sss. Fixed a bug that could cause reserved words to not be recognized in a
1691 for statement without the `in' inside a command substitution.
1692
1693 ttt. Fixed a bug that could cause a double-free in a timed command with an
1694 expansion error.
1695
1696 uuu. Fixed a bug that could cause a core dump if a script switches from a UTF-8
1697 locale to a different locale after displaying a lone surrogate character.
1698
1699 vvv. Fixed cases where bash prematurely removed FIFOs attached to process
1700 substitutions.
1701
1702 www. Fixed a problem with calculating the size of the table that stores exit
1703 statuses from background processes when the child process resource limit
1704 is very large.
1705
1706 xxx. Fixed a memory leak with functions using `return' when using FIFOs for
1707 standard input.
1708
1709 yyy. `wait' without arguments attempts to wait for all active process
1710 substitution processes.
1711
1712 zzz. Fixed a bug where an indirect parameter was subjected to word splitting
1713 when trying to find the indirected variable name.
1714
1715 aaaa. Fixed a bug that could allow restricted shell users to add commands to
1716 the hash table.
1717
1718 bbbb. When using the `!(patlist)' extended globbing operator, a filename
1719 beginning with a `.' that doesn't match any of the patterns is not
1720 returned as a match if leading dots must be matched explicitly.
1721
1722 cccc. Fixed a bug that could cause line number and source file information for
1723 a function definition to be incorrect if there are multiple definitions.
1724
1725 dddd. Fixed a bug that could cause builtins like `readonly' to behave
1726 differently when applied to arrays and scalar variables within functions.
1727
1728 eeee. Fixed a bug that could cause alias expansion to add an extra space to
1729 a quoted string that begins outside the alias expansion.
1730
1731 ffff. Fixed a bug that could result in unwanted alias expansion after timing
1732 the null command.
1733
1734 gggg. Fixed a bug that could cause a core dump if a timestamp in a history
1735 file overflowed a time_t.
1736
1737 hhhh. Restricted shells can no longer redirect from /dev/tcp or /dev/udp, since
1738 the kernel calls make those file descriptors read-write.
1739
1740 iiii. Fixed a problem with splitting double-quoted words for programmable
1741 completion when the double quote immediately follows another word
1742 delimiter.
1743
1744 jjjj. Fixed a bug resulting in a use-after-free if two file descriptors share
1745 the same input buffer.
1746
1747 kkkk. The error message resulting from ${x:?} and ${x?} now differs depending
1748 on whether the variable is null or unset.
1749
1750 llll. In Posix mode, the shell exits if a variable assignment fails and precedes
1751 an empty simple command (after expansion).
1752
1753 mmmm. Fixed a timing problem with SIGALRM that could cause the read builtin to
1754 drop characters.
1755
1756 nnnn. Added code to deal with kill(2) failing to send the shell a fatal signal
1757 due to Linux pid namespace peculiarities.
1758
1759 oooo. Fixed a bug that made \C-@ (NUL) unusable in key sequences used for
1760 `bind -x' commands.
1761
1762 pppp. Fixed a bug that could cause SIGINT recursion when running an external
1763 command in a trap the shell takes after a command exits due to SIGINT.
1764
1765 qqqq. Make sure the shell turns off job control before running the command-
1766 not-found handle, so the command doesn't try to manipulate process
1767 groups.
1768
1769 rrrr. Fixed a problem with timing process substitutions that caused the shell
1770 to print timing information for the calling command.
1771
1772 ssss. Fixed a bug that caused backquotes in a here-document delimiter to mark
1773 the delimiter as quoted (inhibiting expansion of the here-document
1774 contents).
1775
1776 tttt. Fixed several problems with 0x01 and 0x177 in case pattern lists and
1777 conditional command pattern matches.
1778
1779 uuuu. Fixed a bug that could cause the pattern matching engine to not recognize
1780 locale-specific character classes.
1781
1782 vvvv. The auto-configuration now tests for /dev/stdin and /dev/fd independently.
1783
1784 wwww. The `globstar' code now skips over symbolic links to directories,
1785 preventing them from being scanned twice.
1786
1787 xxxx. When running `bind -x' commands, bash now sets READLINE_POINT based on
1788 the number of characters in the readline line buffer, not the number of
1789 bytes.
1790
1791 yyyy. Fixed a problem that could cause recursive trap evaluation of the RETURN
1792 trap when using `eval return'.
1793
1794 zzzz. Fixed a bug with expanding 0x01 in an unquoted here-document.
1795
1796 aaaaa. The process substitution code now closes and unlinks FIFOs when the
1797 process on the other side exits, in order to prevent SIGPIPE or
1798 waiting until a FIFO opened for read has a writer.
1799
1800 bbbbb. Fixed a bug with recursive calls to the parser overwriting the token in
1801 an {id}>foo construct.
1802
1803 ccccc. After a Posix discussion, the pattern matching engine just skips over
1804 invalid character classes in bracket expressions, instead of matching
1805 them like individual characters in the expression.
1806
1807 ddddd. Fixed a posix-mode problem with variable scoping when creating variables
1808 from assignment statements preceding special builtins.
1809
1810 eeeee. Fixed a bug that could cause patterns containing backslashes to not be
1811 run through the pattern matching engine.
1812
1813 fffff. Fixed a bug that could cause redirections to compound commands to not
1814 be `undone' if the file descriptor in the redirection was closed when
1815 the redirection was initially processed.
1816
1817 ggggg. Fixed a bug that could cause buffer corruption when using `bind -x' in
1818 a command execute as a result of a key binding installed by `bind -x'.
1819
1820 2. Changes to Readline
1821
1822 a. Added a guard to prevent nested macros from causing an infinite expansion
1823 loop.
1824
1825 b. Instead of allocating enough history list entries to hold the maximum list
1826 size, cap the number allocated initially.
1827
1828 c. Added a strategy to avoid allocating huge amounts of memory if a block of
1829 history entries without timestamps occurs after a block with timestamps.
1830
1831 d. Added support for keyboard timeouts when an ESC character is the last
1832 character in a macro.
1833
1834 e. There are several performance improvements when in a UTF-8 locale.
1835
1836 f. Readline does a better job of preserving the original set of blocked
1837 signals when using pselect() to wait for input.
1838
1839 g. Fixed a bug that caused multibyte characters in macros to be mishandled.
1840
1841 h. Fixed several bugs in the code that calculates line breaks when expanding
1842 prompts that span several lines, contain multibyte characters, and contain
1843 invisible character seqeuences.
1844
1845 i. Fixed several bugs in cursor positioning when displaying lines with prompts
1846 containing invisible characters and multibyte characters.
1847
1848 j. When performing case-insensitive completion, Readline no longer sorts the
1849 list of matches unless directed to do so.
1850
1851 k. Fixed a problem with key sequences ending with a backslash.
1852
1853 l. Fixed out-of-bounds and free memory read errors found via fuzzing.
1854
1855 m. Fixed several cases where the mark was set to an invalid value.
1856
1857 n. Fixed a problem with the case-changing operators in the case where the
1858 lower and upper case versions of a character do not have the same number
1859 of bytes.
1860
1861 o. Handle incremental and non-incremental search character reads returning EOF.
1862
1863 p. Handle the case where a failing readline command at the end of a multi-key
1864 sequence could be misinterpreted.
1865
1866 q. The history library now prints a meaningful error message if the history
1867 file isn't a regular file.
1868
1869 r. Fixed a problem with vi-mode redo (`.') on a command when trying to replace
1870 a multibyte character.
1871
1872 s. The key binding code now attempts to remove a keymap if a key unbinding
1873 leaves it empty.
1874
1875 t. Fixed a line-wrapping issue that caused problems for some terminal
1876 emulators.
1877
1878 u. If there is a key bound to the tty's VDISCARD special character, readline
1879 disables VDISCARD while it is active.
1880
1881 v. Fixed a problem with exiting bracketed paste mode on terminals that assume
1882 the bracketed paste mode character sequence contains visible characters.
1883
1884 w. Fixed a bug that could cause a key binding command to refer to an
1885 uninitialized variable.
1886
1887 3. New Features in Bash
1888
1889 a. The `wait' builtin can now wait for the last process substitution created.
1890
1891 b. There is an EPOCHSECONDS variable, which expands to the time in seconds
1892 since the Unix epoch.
1893
1894 c. There is an EPOCHREALTIME variable, which expands to the time in seconds
1895 since the Unix epoch with microsecond granularity.
1896
1897 d. New loadable builtins: rm, stat, fdflags.
1898
1899 e. BASH_ARGV0: a new variable that expands to $0 and sets $0 on assignment.
1900
1901 f. When supplied a numeric argument, the shell-expand-line bindable readline
1902 command does not perform quote removal and suppresses command and process
1903 substitution.
1904
1905 g. `history -d' understands negative arguments: negative arguments offset from
1906 the end of the history list.
1907
1908 h. The `name' argument to the `coproc' reserved word now undergoes word
1909 expansion, so unique coprocs can be created in loops.
1910
1911 i. A nameref name resolution loop in a function now resolves to a variable by
1912 that name in the global scope.
1913
1914 j. The `wait' builtin now has a `-f' option, which signifies to wait until the
1915 specified job or process terminates, instead of waiting until it changes
1916 state.
1917
1918 k. There is a define in config-top.h that allows the shell to use a static
1919 value for $PATH, overriding whatever is in the environment at startup, for
1920 use by the restricted shell.
1921
1922 l. Process substitution does not inherit the `v' option, like command
1923 substitution.
1924
1925 m. If a non-interactive shell with job control enabled detects that a foreground
1926 job died due to SIGINT, it acts as if it received the SIGINT.
1927
1928 n. The SIGCHLD trap is run once for each exiting child process even if job
1929 control is not enabled when the shell is in Posix mode.
1930
1931 o. A new shopt option: localvar_inherit; if set, a local variable inherits the
1932 value of a variable with the same name at the nearest preceding scope.
1933
1934 p. `bind -r' now checks whether a key sequence is bound before binding it to
1935 NULL, to avoid creating keymaps for a multi-key sequence.
1936
1937 q. A numeric argument to the line editing `operate-and-get-next' command
1938 specifies which history entry to use.
1939
1940 r. The positional parameters are now assigned before running the shell startup
1941 files, so startup files can use $@.
1942
1943 s. There is a compile-time option that forces the shell to disable the check
1944 for an inherited OLDPWD being a directory.
1945
1946 t. The `history' builtin can now delete ranges of history entries using
1947 `-d start-end'.
1948
1949 u. The `vi-edit-and-execute-command' bindable readline command now puts readline
1950 back in vi insertion mode after executing commands from the edited file.
1951
1952 v. The command completion code now matches aliases and shell function names
1953 case-insensitively if the readline completion-ignore-case variable is set.
1954
1955 w. There is a new `assoc_expand_once' shell option that attempts to expand
1956 associative array subscripts only once.
1957
1958 x. The shell only sets up BASH_ARGV and BASH_ARGC at startup if extended
1959 debugging mode is active. The old behavior of unconditionally setting them
1960 is available as part of the shell compatibility options.
1961
1962 y. The `umask' builtin now allows modes and masks greater than octal 777.
1963
1964 z. The `times' builtin now honors the current locale when printing a decimal
1965 point.
1966
1967 aa. There is a new (disabled by default, undocumented) shell option to enable
1968 and disable sending history to syslog at runtime.
1969
1970 4. New Features in Readline
1971
1972 a. Non-incremental vi-mode search (`N', `n') can search for a shell pattern, as
1973 Posix specifies (uses fnmatch(3) if available).
1974
1975 b. There are new `next-screen-line' and `previous-screen-line' bindable
1976 commands, which move the cursor to the same column in the next, or previous,
1977 physical line, respectively.
1978
1979 c. There are default key bindings for control-arrow-key key combinations.
1980
1981 d. A negative argument (-N) to `quoted-insert' means to insert the next N
1982 characters using quoted-insert.
1983
1984 e. New public function: rl_check_signals(), which allows applications to
1985 respond to signals that readline catches while waiting for input using
1986 a custom read function.
1987
1988 f. There is new support for conditionally testing the readline version in an
1989 inputrc file, with a full set of arithmetic comparison operators available.
1990
1991 g. There is a simple variable comparison facility available for use within an
1992 inputrc file. Allowable operators are equality and inequality; string
1993 variables may be compared to a value; boolean variables must be compared to
1994 either `on' or `off'; variable names are separated from the operator by
1995 whitespace.
1996
1997 ------------------------------------------------------------------------------
1998 This document details the changes between this version, bash-4.4-release, and
1999 the previous version, bash-4.4-rc2.
2000
2001 1. Changes to Bash
2002
2003 a. Fixed a bug that could potentially result in a crash due to an integer
2004 overflow.
2005
2006 b. Fixed a bug in where commands printed due to `set -x' could be incorrectly
2007 quoted if being printed in contexts where they haven't yet been expanded.
2008
2009 c. Fixed several memory leaks.
2010
2011 d. Fixed a bug that could potentially cause the terminal attributes to be
2012 set incorrectly by a command run from a programmable completion.
2013
2014 e. Fixed several potential buffer overflow issues in the word expansion code.
2015
2016 2. Changes to Readline
2017
2018 3. New Features in Bash
2019
2020 4. New Features in Readline
2021 ------------------------------------------------------------------------------
2022 This document details the changes between this version, bash-4.4-rc2, and
2023 the previous version, bash-4.4-beta2.
2024
2025 1. Changes to Bash
2026
2027 a. Fixed an out-of-bounds read in the redirection operator completion code.
2028
2029 b. Fixed execution context so `until continue' doesn't disable execution for
2030 subsequent commands.
2031
2032 c. Fixed trap handling code so traps don't inherit a command's temporary
2033 environment.
2034
2035 d. Fixed a bug that resulted in incorrect line numbers when a function is
2036 defined as part of another function's execution.
2037
2038 e. Fixed a bug in the expansion of ${a[@]} in contexts where word splitting
2039 is not performed and $IFS is not the default.
2040
2041 f. Fixed a bug that caused ''"$@" to not expand to an empty argument when
2042 there are no positional parameters.
2043
2044 g. Fixed a bug that caused a shell compiled without job control to use the
2045 incorrect exit status for builtin commands preceded by a command executed
2046 from the file system that causes the shell to call waitpid().
2047
2048 h. Improved word completion for quoted strings containing unterminated command
2049 substitutions with embedded double quotes.
2050
2051 2. Changes to Readline
2052
2053 a. Fixed a bug that caused mode strings to be displayed incorrectly if the
2054 prompt was shorter than the mode string.
2055
2056 3. New Features in Bash
2057
2058 a. Using ${a[@]} or ${a[*]} with an array without any assigned elements when
2059 the nounset option is enabled no longer throws an unbound variable error.
2060
2061 4. New Features in Readline
2062
2063 a. New application-callable function: rl_pending_signal(): returns the signal
2064 number of any signal readline has caught but not yet handled.
2065
2066 b. New application-settable variable: rl_persistent_signal_handlers: if set
2067 to a non-zero value, readline will enable the readline-6.2 signal handler
2068 behavior in callback mode: handlers are installed when
2069 rl_callback_handler_install is called and removed removed when a complete
2070 line has been read.
2071
2072 ------------------------------------------------------------------------------
2073 This document details the changes between this version, bash-4.4-beta2, and
2074 the previous version, bash-4.4-rc1.
2075
2076 1. Changes to Bash
2077
2078 a. Fixed a memory leak when processing ${!var[@]}.
2079
2080 b. Fixed a bug that caused subshells to free trap strings associated with
2081 inherited signals.
2082
2083 c. Inheriting BASHOPTS from the environment now works to force actions
2084 associated with enabling an option, instead of just marking the option
2085 as enabled.
2086
2087 d. Fixed a bug that allowed assignments to BASH_CMDS when the shell was in
2088 restricted mode.
2089
2090 e. Fixed a bug caused by an accidental omission of part of the original patch
2091 for EXECIGNORE.
2092
2093 e. Prompt expansion now quotes the results of the \s, \h, and \H expansions.
2094
2095 f. Fixed a bug that caused parsing errors in command substitutions with
2096 consecutive case statements separated by newlines.
2097
2098 g. Updated logic used to decide whether bash is running inside an emacs
2099 terminal emulator to work with future emacs versions.
2100
2101 h. Fixed two extended pattern matching bugs caused by premature short-
2102 circuiting.
2103
2104 i. Fixed a memory leak in the code that removes duplicate history entries.
2105
2106 j. There are a number of bug fixes to coproc, mapfile, declare, unset,
2107 and assignment statements that prevent nameref variables from creating
2108 and unsetting variables with invalid names.
2109
2110 k. Fixed a bug that caused variables to be inadvertently marked as both an
2111 associative and an indexed array.
2112
2113 l. Fixed a bug that caused `bash -c' to not run a trap specified in the
2114 command string.
2115
2116 j. There are a number of bug fixes to coproc, mapfile, declare, and assignment
2117 statements that prevent nameref variables from overwriting or modifying
2118 attributes of readonly variables.
2119
2120 k. Fixed a bug that caused command substitution to attempt to set the
2121 terminal's process group incorrectly.
2122
2123 l. Fixed a bug that could cause prompt string expansion to display error
2124 messages when the `nounset' shell option is set.
2125
2126 m. Fixed a bug that caused "$@" to not expand to an empty string under the
2127 circumstances when Posix says it should ("${@-${@-$@}}").
2128
2129 n. Fixed several bugs caused by referencing nameref variables whose values
2130 are names of unset variables (or names that are valid for referencing
2131 but not assignment), including creating variables in the temporary
2132 environment.
2133
2134 o. Function tracing and error tracing are disabled if --debugger is supplied
2135 at startup but the shell can't find the debugger start file.
2136
2137 p. Fixed a bug when IFS is used as the control variable in a for statement.
2138
2139 q. Fixed a bug with SIGINT received by a command substitution in an interactive
2140 shell.
2141
2142 r. The checks for nameref variable self-references are more thorough.
2143
2144 s. Fixed several bugs with multi-line aliases.
2145
2146 t. Fixed `test' to handle the four-argument case where $1 == '(' and
2147 $4 == ')'.
2148
2149 u. Fixed a bug in the expansion of $* in the cases where word splitting is
2150 not performed.
2151
2152 v. Fixed a bug in execution of case statements where IFS includes the
2153 pattern matching characters.
2154
2155 2. Changes to Readline
2156
2157 a. When refreshing the line as the result of a key sequence, Readline attempts
2158 to redraw only the last line of a multiline prompt.
2159
2160 b. Fixed an issue that caused completion of git commands to display
2161 incorrectly when using colored-completion-prefix.
2162
2163 c. Fixed several redisplay bugs having to do with multibyte characters and
2164 invisible characters in prompt strings.
2165
2166 3. New Features in Bash
2167
2168 a. Value conversions (arithmetic expansions, case modification, etc.) now
2169 happen when assigning elements of an array using compound assignment.
2170
2171 b. There is a new option settable in config-top.h that makes multiple
2172 directory arguments to `cd' a fatal error.
2173
2174 c. Bash now uses mktemp() when creating internal temporary files; it produces
2175 a warning at build time on many Linux systems.
2176
2177 4. New Features in Readline
2178
2179 a. The default binding for ^W in vi mode now uses word boundaries specified
2180 by Posix (vi-unix-word-rubout is bindable command name).
2181
2182 b. rl_clear_visible_line: new application-callable function; clears all
2183 screen lines occupied by the current visible readline line.
2184
2185 c. rl_tty_set_echoing: application-callable function that controls whether
2186 or not readline thinks it is echoing terminal output.
2187
2188 d. Handle >| and strings of digits preceding and following redirection
2189 specifications as single tokens when tokenizing the line for history
2190 expansion.
2191
2192 e. Fixed a bug with displaying completions when the prefix display length
2193 is greater than the length of the completions to be displayed.
2194
2195 f. The :p history modifier now applies to the entire line, so any expansion
2196 specifying :p causes the line to be printed instead of expanded.
2197
2198 ------------------------------------------------------------------------------
2199 This document details the changes between this version, bash-4.4-rc1, and
2200 the previous version, bash-4.4-beta.
2201
2202 1. Changes to Bash
2203
2204 a. Fixed several problems with bash completion not special-casing bash syntax
2205 constructs.
2206
2207 b. Fixed a bug that caused the mapfile builtin to not create array variables
2208 when a variable of the same name appears in the temporary environment.
2209
2210 c. Fixed a bug that caused prompt expansion to loop when PS1 contained a
2211 syntax error.
2212
2213 d. Fixed a bug that caused the ${array[@]@A} expansion to split the results
2214 even when double-quoted.
2215
2216 e. There is a new implementation of the code that saves the last CHILD_MAX
2217 exited background pids so their status can be queried later.
2218
2219 f. Bash-4.4 can now be configured and built on very old versions of Solaris 2.
2220
2221 g. Fixed problems with --help support for several builtins.
2222
2223 h. Fixed values added to BASH_SOURCE and BASH_LINENO for functions inherited
2224 from the environment.
2225
2226 i. Fixed a bug that caused background processes run from non-interactive shells
2227 with job control enabled to place the terminal in the wrong process group
2228 under certain circumstances.
2229
2230 j. Fixed a bug that caused `fc' to return an incorrect exit status when
2231 executing commands from the history list.
2232
2233 k. Fixed a bug that caused the shell to exit when a process substitution
2234 received a SIGINT when run in certain terminal emulators.
2235
2236 l. EXECIGNORE now honors the setting of `extglob' when attempting to match
2237 executable names.
2238
2239 m. Fixed a bug where `return' used the wrong exit status when executed in a
2240 DEBUG trap.
2241
2242 n. Fixed a bug that caused a command containing a here-document and an escaped
2243 newline to be stored in the history list incorrectly.
2244
2245 o. Fixed a bug that caused set -e to be honored in cases of builtins invoking
2246 other builtins when it should be ignored.
2247
2248 p. Fixed a bug that caused `readonly' and `export' to create local array
2249 variables when used within shell functions.
2250
2251 q. Fixed a bug that allowed subshells begun to execute process substitutions
2252 to have access to the command's temporary environment.
2253
2254 r. Fixed a bug that could cause the shell to dump core when receiving a
2255 SIGCHLD for which a trap has been set while running in posix mode.
2256
2257 s. Fixed a bug that caused bash to not restore BASH_ARGC, BASH_ARGV,
2258 BASH_SOURCE, BASH_LINENO, and FUNCNAME if the shell received a SIGINT
2259 while reading commands from a file while executing `.'.
2260
2261 t. Fixed a bug that caused the `-o history' option to have no effect when
2262 supplied on the command line when starting a new shell.
2263
2264 u. Fixed a bug that caused history expansions occurring in command
2265 substitutions to not be performed.
2266
2267 v. Fixed a bug that caused `eval' run in a non-interactive shell to disable
2268 history expansion for the remainder of the shell script, even if the script
2269 had previously enabled it.
2270
2271 w. Fixed a bug that caused "$@" to not expand to multiple words when IFS is set
2272 to the empty string.
2273
2274 x. Fixed a bug that caused process and command substitution to inherit output
2275 buffered in the stdio library but not written.
2276
2277 y. Fixed a bug that caused a terminating signal received during `echo' to run
2278 an exit trap in a signal handler context.
2279
2280 z. Fixed a bug that caused a builtin command containing a process substitution
2281 to return the wrong exit status.
2282
2283 aa. Fixed a bug that caused `()' subshells with piped input to incorrectly
2284 redirect the standard input of some of the commands in the subshell from
2285 /dev/null.
2286
2287 bb. The history builtin now uses more descriptive error messages for missing or
2288 invalid timestamps.
2289
2290 2. Changes to Readline
2291
2292 a. The history file writing functions only attempt to create and use a backup
2293 history file if the history file exists and is a regular file.
2294
2295 b. Fixed an out-of-bounds read in readline's internal tilde expansion
2296 interface.
2297
2298 c. Fixed several redisplay bugs with prompt strings containing multibyte
2299 and non-visible characters whose physical length is longer than the screen
2300 width.
2301
2302 d. Fixed a redisplay bug with prompt strings containing invisible characters
2303 whose physical length exceeds the screen width and using incremental search.
2304
2305 e. Readline prints more descriptive error messages when it encounters errors
2306 while reading an inputrc file.
2307
2308 f. Fixed a bug in the character insertion code that attempts to optimize
2309 typeahead when it reads a character that is not bound to self-insert and
2310 resets the key sequence state.
2311
2312 3. New Features in Bash
2313
2314 a. BASH_COMPAT and FUNCNEST can be inherited and set from the shell's initial
2315 environment.
2316
2317 b. inherit_errexit: a new `shopt' option that, when set, causes command
2318 substitutions to inherit the -e option. By default, those subshells disable
2319 -e. It's enabled as part of turning on posix mode.
2320
2321 c. New prompt string: PS0. Expanded and displayed by interactive shells after
2322 reading a complete command but before executing it.
2323
2324 d. Interactive shells now behave as if SIGTSTP/SIGTTIN/SIGTTOU are set to
2325 SIG_DFL when the shell is started, so they are set to SIG_DFL in child
2326 processes.
2327
2328 e. Posix-mode shells now allow double quotes to quote the history expansion
2329 character.
2330
2331 f. OLDPWD can be inherited from the environment if it names a directory.
2332
2333 g. Shells running as root no longer inherit PS4 from the environment, closing
2334 a security hole involving PS4 expansion performing command substitution.
2335
2336 h. If executing an implicit `cd' when the `autocd' option is set, bash will
2337 now invoke a function named `cd' if one exists before executing the `cd'
2338 builtin.
2339
2340 4. New Features in Readline
2341
2342 a. If an incremental search string has its last character removed with DEL,
2343 the resulting empty search string no longer matches the previous line.
2344
2345 b. If readline reads a history file that begins with `#' (or the value of
2346 the history comment character) and has enabled history timestamps, the
2347 history entries are assumed to be delimited by timestamps. This allows
2348 multi-line history entries.
2349
2350 c. Readline now throws an error if it parses a key binding without a
2351 terminating `:' or whitespace.
2352
2353 ------------------------------------------------------------------------------
2354 This document details the changes between this version, bash-4.4-beta, and
2355 the previous version, bash-4.4-alpha.
2356
2357 1. Changes to Bash
2358
2359 a. Fixed two bugs that caused out-of-bounds reads when skipping over assignment
2360 statements while finding the word on which to perform programmable
2361 completion.
2362
2363 b. Fixed a memory leak in programmable completion.
2364
2365 c. Fixed a bug that could cause the shell to crash when interrupting the
2366 wait builtin.
2367
2368 d. Fixed a bug that caused ${!vvv@} to be interpreted as introducing the new
2369 `@' operator.
2370
2371 e. Fixed a bug that caused the && and || operators to be incorrectly optimized.
2372
2373 f. The shell now undoes redirections before exiting the shell when the `-e'
2374 option is enabled, and a shell function fails.
2375
2376 g. History expansion now skips over the history expansion character in command
2377 and process substitution.
2378
2379 h. Fixed a bug that caused stray '\001' characters to be added to the output
2380 of `declare -p'.
2381
2382 i. Fixed a memory leak when processing declare commands that perform compound
2383 array assignments.
2384
2385 j. Fixed a bug that could cause the shell to crash when reading input from a
2386 file and the limit on open file descriptors is high.
2387
2388 k. Fixed a bug that caused the ERR and RETURN traps to be unset if they were
2389 set in a shell function but unset previously.
2390
2391 l. Fixed a bug that caused several signals to be ignored if `exec' failed in
2392 an interactive shell.
2393
2394 m. A posix-mode non-interactive shell now considers a parameter expansion error
2395 to be a fatal error.
2396
2397 n. The `time' command now prints timing statistics for failed commands when
2398 the -e option is enabled.
2399
2400 o. Fixed a bug that caused the shell to crash when attempting to indirectly
2401 expand a shell variable with an invalid name.
2402
2403 p. Fixed a bug that caused the shell to crash when running a trap containing
2404 a process substitution.
2405
2406 q. Bash now prints the keyword `function' before a function with the same name
2407 as a reserved word when using `declare -f' to avoid parse errors when
2408 reusing the output as input.
2409
2410 r. Fixed a bug that caused the shell to crash when using declare -g to attempt
2411 to redefine an existing global indexed array variable as an associative
2412 array.
2413
2414 s. Fixed a memory leak that occurred when interrupting brace expansions
2415 generating a sequence.
2416
2417 t. Fixed a bug that resulted in alias expansion in redirections.
2418
2419 u. The `declare -a' and `declare -A' commands now print fewer warnings when
2420 attempting to create and initialize an array at the same time, but
2421 relying on word expansions to construct the compound assignment.
2422
2423 v. The `help' builtin now behaves better in locales where each wide
2424 character occupies more than one display column.
2425
2426 w. The `read' builtin no longer has a possible race condition when a timeout
2427 occurs.
2428
2429 x. Fixed several expansion problems encountered when IFS="'".
2430
2431 y. Fixed a problem with the expansion of $'\c?'.
2432
2433 z. Bash no longer splits the expansion of here-strings, as the documentation
2434 has always said.
2435
2436 aa. Bash now puts `s' in the value of $- if the shell is reading from standard
2437 input, as Posix requires.
2438
2439 bb. Fixed a bug that caused the shell to crash if invoked with a NULL
2440 environment.
2441
2442 cc. The shell now only trusts an inherited value for $PWD if it begins with a
2443 `/'.
2444
2445 dd. Fixed a memory leak when creating local array variables and assigning to
2446 them using compound assignment with the `declare' builtin.
2447
2448 ee. Fixed a bug that could cause the shell to crash when processing nested here
2449 documents inside a command substitution.
2450
2451 ff. Array keys and values are now displayed using $'...' quoting where
2452 appropriate.
2453
2454 gg. Fixed a bug that could cause the shell to crash if the replacement string
2455 in pattern substitution was NULL.
2456
2457 hh. Fixed a bug that could cause the shell to crash if a command substitution
2458 contained a non-fatal syntax error.
2459
2460 ii. Fixed a bug that could cause the shell to crash if variable indirection
2461 resulted in a NULL variable.
2462
2463 jj. Fixed a bug that could cause the shell to crash if a long string contained
2464 multiple unterminated parameter expansion constructs.
2465
2466 kk. Improved the code that acts on SIGINT received while waiting for a child
2467 process only if the child exits due to SIGINT.
2468
2469 ll. $BASH_SUBSHELL now has more consistent values in asynchronous simple
2470 commands.
2471
2472 2. Changes to Readline
2473
2474 a. Colored completion prefixes are now displayed using a different color, less
2475 likely to collide with files.
2476
2477 b. Fixed a bug that caused vi-mode character search to misbehave when
2478 running in callback mode.
2479
2480 c. Fixed a bug that caused output to be delayed when input is coming from a
2481 macro in vi-mode.
2482
2483 d. Fixed a bug that caused the vi-mode `.' command to misbehave when redoing
2484 a multi-key key sequence via a macro.
2485
2486 e. Fixed a bug that caused problems with applications that supply their own
2487 input function when performing completion.
2488
2489 f. When read returns -1/EIO when attempting to read a key, return an error
2490 instead of line termination back to the caller.
2491
2492 g. Updated tty auditing feature based on patch from Red Hat.
2493
2494 h. Fixed a bug that could cause the history library to crash on overflows
2495 introduced by malicious editing of timestamps in the history file.
2496
2497 3. New Features in Bash
2498
2499 a. `make install' now installs the example loadable builtins and a set of
2500 bash headers to use when developing new loadable builtins.
2501
2502 b. `enable -f' now attempts to call functions named BUILTIN_builtin_load when
2503 loading BUILTIN, and BUILTIN_builtin_unload when deleting it. This allows
2504 loadable builtins to run initialization and cleanup code.
2505
2506 c. There is a new BASH_LOADABLES_PATH variable containing a list of directories
2507 where the `enable -f' command looks for shared objects containing loadable
2508 builtins.
2509
2510 d. The `complete_fullquote' option to `shopt' changes filename completion to
2511 quote all shell metacharacters in filenames and directory names.
2512
2513 e. The `kill' builtin now has a `-L' option, equivalent to `-l', for
2514 compatibility with Linux standalone versions of kill.
2515
2516 4. New Features in Readline
2517 ------------------------------------------------------------------------------
2518 This document details the changes between this version, bash-4.4-alpha, and
2519 the previous version, bash-4.3-release.
2520
2521 1. Changes to Bash
2522
2523 a. A bug that caused pipelines to be corrupted while running the DEBUG trap
2524 was fixed.
2525
2526 b. A bug that accidentally omitted the `-R' unary operator from `test' was
2527 fixed.
2528
2529 c. A bug that could cause the shell to not restore the terminal's process
2530 group on shell exit was fixed.
2531
2532 d. Several changes were made to programmable completion to accommodate
2533 assumptions made by the bash-completion package.
2534
2535 e. Bash no longer inhibits C-style escape processing ($'...') while performing
2536 pattern substitution word expansions.
2537
2538 f. Fixed a bug that caused `return' executed from a trap handler to use the
2539 wrong return status when one was not supplied as an argument.
2540
2541 g. In Posix mode, defining a function with the same name as a special
2542 builtin is now an error, fatal only when the shell is not interactive.
2543
2544 h. Fixed a bug that caused compound array assignments to discard unset or null
2545 variables used as subscripts, thereby making it appear as if the index was
2546 not present.
2547
2548 i. Fixed a bug that caused extended glob patterns to incorrectly match
2549 filenames with a leading `.'.
2550
2551 j. Fixed a bug involving sign extension when reallocating the input line
2552 after a history expansion, causing segmentation faults.
2553
2554 k. Bash now does a better job at identifying syntax errors during word
2555 completion and tailoring completion appropriately.
2556
2557 l. Bash now uses the current locale's decimal point in command timing output.
2558
2559 m. Fixed a bug that caused segmentation faults while reading here documents if
2560 PS2 contains a command substitution.
2561
2562 n. There are several changes to how $@ is expanded when unquoted but in a
2563 context where word splitting is not performed (e.g., on the rhs of an
2564 assignment or in a conditional command).
2565
2566 o. Bash now quotes command hash table entries that contain shell metacharacters
2567 when displaying hash table contents.
2568
2569 p. Fixed a potential file descriptor leak when dup2() fails while performing a
2570 redirection.
2571
2572 q. Fixed a bug that caused directory names evaluated during word completion to
2573 be dequoted twice.
2574
2575 r. Fixed several bugs which could result in indirect variable expansion and
2576 namerefs creating variables with invalid names or referencing variables
2577 set to the empty string.
2578
2579 s. Fixed a bug that caused bash to not expand $0 in word expansions where it
2580 should.
2581
2582 t. Fixed a bug that caused bash to perform process substitution if <(
2583 appeared inside an arithmetic context.
2584
2585 u. Fixed a bug in extglob pattern parsing that caused slashes in the pattern
2586 to be confused as directory names.
2587
2588 v. Fixed several bugs with treatment of invisible variables (variables with
2589 attributes that are unset because they have never been assigned values).
2590
2591 w. Fixed a bug that caused the `read' builtin to not clean up readline's
2592 state when using the -e and -t options together and the read timed out.
2593
2594 x. Fixed a bug that caused the shell to exit with the wrong (but non-zero)
2595 value if a command was not found or was not executable.
2596
2597 y. Fixed a bug that caused the `time' reserved word to not be recognized as
2598 such in all contexts where it should have been.
2599
2600 z. Fixed a bug that caused the shell to close process substitution file
2601 descriptors when executing a script without the `#!' leading line.
2602
2603 aa. Fixed a typo that caused the `compat42' shell option to set the wrong
2604 compatibility level.
2605
2606 bb. The shell now handles process substitution commands with embedded
2607 parentheses the same way as it does when parsing command substitution.
2608
2609 cc. Fixed a bug that caused nested pipelines and the `lastpipe' shell option
2610 to produce core dumps.
2611
2612 dd. Fixed a bug that caused patterns containing `*' to match pathnames in cases
2613 where slashes must be matched explicitly.
2614
2615 ee. Fixed a problem with patterns containing `:' in colon-separated variables
2616 like GLOBIGNORE.
2617
2618 ff. Fixed a bug that caused indirect variable expansion using indexed arrays to
2619 always use index 0.
2620
2621 gg. Fixed a parsing problem that caused quoted newlines immediately following a
2622 command substitution to be mishandled in certain cases.
2623
2624 hh. Fixed a potential buffer overflow on systems without locale_charset or the
2625 bash replacement.
2626
2627 ii. Fixed a bug that caused background processes to modify the terminal's
2628 process group under certain circumstances.
2629
2630 jj. Asynchronous commands now always set $? to 0 and are not affected by
2631 whether or not the command's exit status is being inverted.
2632
2633 kk. Fixed a problem that caused a line ending with an escaped newline and
2634 containingh a prior `eval' to be incorrectly parsed.
2635
2636 ll. Fixed an issue with programmable completion and `!' in extglob patterns
2637 used as arguments to `compgen -X'.
2638
2639 mm. Word completion now treats the two-character token `>|' as requiring
2640 filename expansion.
2641
2642 nn. Bash no longer expands tildes in $PATH elements while in Posix mode.
2643
2644 oo. Fixed a bug that caused bash to not clean up readline's state, including
2645 the terminal settings, if it received a fatal signal while in a readline()
2646 call (including `read -e' and `read -s').
2647
2648 pp. Fixed bug that caused importing shell functions from the environment to
2649 execute additional commands following the function.
2650
2651 qq. Fixed a bug that caused the parser to return a lookahead character pushed
2652 back by a previous call, even when on another line.
2653
2654 rr. Fixed a bug that caused many here-documents or many nested case statements
2655 to overflow an internal stack.
2656
2657 ss. Changed the way bash encodes exported functions for inclusion in the
2658 environment to avoid name collisions with valid variable names and to
2659 indicate that they are exported functions.
2660
2661 tt. Fixed a bug that could result in an invalid memory access when processing
2662 a here document delimited by end of file or end of string.
2663
2664 uu. Fixed a bug that could cause an invalid memory access if a command was run
2665 before initializing the job control framework.
2666
2667 vv. When in Posix mode, bash prints shell function definitions as Posix
2668 specifies them, without the leading `function' keyword.
2669
2670 ww. The variable attribute display builtins no longer display variables with
2671 invalid names that were imported from the environment.
2672
2673 xx. Fixed a bug that could allow `break' or `continue' executed from shell
2674 functions to affect loops running outside of the function.
2675
2676 yy. Fixed a bug that could cause a restricted shell to attempt to import shell
2677 functions from the environment.
2678
2679 zz. The shell now allows double-quoted identifiers in arithmetic expressions.
2680
2681 aaa. Fixed a bug that could allow scalar variables subscripted using [@] in
2682 word expansions to be incorrectly quoted.
2683
2684 bbb. The shell now makes sure to ignore SIGTSTP/SIGTTIN/SIGTTOU in child
2685 processes if they were ignored at shell startup, even if job control is
2686 in effect.
2687
2688 ccc. Fixed a bug that could cause $* to be split on spaces when IFS is set to
2689 the empty string.
2690
2691 ddd. Posix says that expanding $* in a pattern context where the expansion is
2692 double-quoted should not treat $* as if it were double quoted.
2693
2694 eee. Bash now restores getopts' internal state between calls to getopts even if
2695 a shell function declares a local copy of OPTIND.
2696
2697 fff. Fixed a bug that could cause `history -r' or `history -n' to read identical
2698 lines from the history file more than once.
2699
2700 ggg. The commands executed by `bind -x' now redisplay at most the final line
2701 of a multi-line prompt, and those commands may return 124 to indicate that
2702 the entire prompt should be redrawn.
2703
2704 hhh. Fixed a bug that could cause `mapfile' to create variables with invalid
2705 names.
2706
2707 iii. The shell only goes into debugging mode when --debugger is supplied if
2708 the debugger initialization file is present.
2709
2710 jjj. Fixed a bug that disallowed an assignment to (implicit) subscript 0 of an
2711 existing array in a declare command that set the readonly attribute.
2712
2713 kkk. Fixed a bug that inadvertently allowed assignments to FUNCNAME to disable
2714 its special status.
2715
2716 lll. Appending to an existing array variable using the compound assignment
2717 syntax (var+=(aaa)) should not affect assignments to existing subscripts
2718 appearing in the compound assignment.
2719
2720 mmm. Fixed a bug that could cause the shell to crash when a variable with a
2721 null value was passed in the temporary environment and the variable's
2722 attributes are modified using `declare' while performing a redirection.
2723
2724 nnn. Fixed a bug in printf so that a missing precision specifier after a `.'
2725 is treated as 0.
2726
2727 ooo. Fixed a bug that attempted to use the internal command timing to time
2728 pipeline components if the pipeline elements are separated by newlines.
2729
2730 ppp. Fixed a bug that caused `declare -al foo=(ONE TWO THREE)' to not lowercase
2731 the values on assignment.
2732
2733 qqq. Bash does a better job of determining whether or not files are executable
2734 when running on Windows, since the X_OK flag to access(2) is not supported.
2735
2736 rrr. Fixed a bug that caused some of the shell's internal traps (e.g., ERR) to
2737 be interrupted (and leave incorrect state) by pending SIGINTs.
2738
2739 sss. Fixed a bug in the bash interface to history expansion to avoid attempting
2740 expansion if the history expansion character occurs in a command
2741 substitution.
2742
2743 ttt. Fixed a bug that caused the select command to crash if the REPLY variable
2744 ends up empty (e.g., if it's made readonly)
2745
2746 uuu. Bash handles backslash-quoting of multibyte characters better when quoting
2747 output that is intended to be reused.
2748
2749 vvv. System-specific changes for: Windows, Cygwin.
2750
2751 www. Fixes for upper and lower-casing multibyte characters, some locales have
2752 characters whose upper and lowercase versions have different numbers of
2753 bytes.
2754
2755 xxx. Fixed a bug that caused the ERR trap in a shell function to have the
2756 wrong value for $LINENO.
2757
2758 yyy. Fixed a bug that resulted in incorrect quoting of regexps for the =~
2759 operator when an open brace appears without a close brace.
2760
2761 zzz. Fixed a bug in the array unset operation that caused it to attempt to
2762 parse embedded single and double quotes.
2763
2764 aaaa. Fixed a bug that caused $* to not expand with the first character of
2765 $IFS as a separator in a context where word splitting will not take
2766 place.
2767
2768 bbbb. Fixed two bugs that could cause the shell to dereference a null pointer
2769 while attempting to print an error message from arithmetic expansion.
2770
2771 cccc. Fixed a bug that resulted in short-circuited evaluation when reading
2772 commands from a string ending in an unquoted backslash, or when sourcing
2773 a file that ends with an unquoted backslash.
2774
2775 dddd. Fixed a bug that resulted in the no-fork optimization not cleaning up
2776 any FIFOs created by process substitution.
2777
2778 eeee. If the -T option is not set, allow the source builtin and shell functions
2779 to set a DEBUG trap that persists after the sourced file or function
2780 returns, instead of restoring the old (unset) value unconditionally.
2781
2782 ffff. Fixed a bug that caused redirections to not be undone on some syntax
2783 errors, e.g., when parsing a command substitution.
2784
2785 gggg. Bash only adds asynchronous commands to the table of background pids
2786 whose status it remembers, to avoid it growing too large during scripts
2787 that create and reap large numbers of child processes. This means that
2788 `wait' no longer works on synchronous jobs, but $? can be used to get
2789 the exit status in those cases.
2790
2791 hhhh. Bash now checks whether or not a shell script argument is a directory
2792 before trying to open it; Posix says implementations may allow open(2)
2793 on a directory.
2794
2795 iiii. Fixed a bug that could cause the shell to set the terminal's process
2796 group to a background process group when running as part of a pipeline.
2797
2798 jjjj. Made a few changes to strings to avoid possible potential negative effects
2799 caused by malicious translations.
2800
2801 kkkk. Fixed a bug that caused the `unset' builtin to continue to treat its
2802 arguments as functions after unsetting a function when invoked with no
2803 options.
2804
2805 llll. Fixed a bug that would not replace empty strings using pattern
2806 substitution even if the pattern matched the empty string.
2807
2808 mmmm. Fixed a bug with word completion that prevented some characters from
2809 being backslash-quoted (backquote, dollar sign).
2810
2811 nnnn. Fixed a bug that prevented a command from the history re-executed by the
2812 `fc' builtin from setting verbose mode.
2813
2814 oooo. Fixed a bug that caused the shell to not enable and disable function
2815 tracing with changes to the `extdebug' shell option.
2816
2817 pppp. Fixed a bug that caused assignments to nameref variables pointing to
2818 unset variables with attributes but no values to create variables with
2819 incorrect names.
2820
2821 qqqq. Fixed a bug that caused `unset' on nameref variables (without -n) to
2822 unset the wrong variable under certain circumstances.
2823
2824 rrrr. Fixed a bug that caused close braces occurring in brace expansions within
2825 command substitutions to incorrectly terminate parameter expansions.
2826
2827 ssss. Fixed a bug that caused `command -p' to temporarily alter $PATH.
2828
2829 tttt. Fixed a bug that caused interactive shells compiled without job control
2830 to return incorrect status values for child processes when running a
2831 single command that creates enough children to use the entire PID space.
2832
2833 uuuu. `esac' should not be recognized as a reserved word when it appears as the
2834 second or later pattern in a case statement pattern list.
2835
2836 vvvv. Fixed a bug that caused the completion code to read past the end of the
2837 readline line buffer while skipping assignment statements to find the
2838 command name.
2839
2840 wwww. Fixed a bug that caused case statements within loops contained in a
2841 command substitution to be parsed incorrectly.
2842
2843 xxxx. Fixed a bug that could cause SIGCHLD handling to be delayed after
2844 running `wait' with no arguments and interrupting it with ^C without
2845 a trap handler installed.
2846
2847 2. Changes to Readline
2848
2849 a. A bug that caused vi-mode `.' to be unable to redo `c', `d', and `y'
2850 commands with modifiers was fixed.
2851
2852 b. Fixed a bug that caused callback mode to dump core when reading a
2853 multiple-key sequence (e.g., arrow keys).
2854
2855 c. Fixed a bug that caused the redisplay code to erase some of the line when
2856 using horizontal scrolling with incremental search.
2857
2858 d. Readline's input handler now performs signal processing if read(2) is
2859 interrupted by SIGALRM or SIGVTALRM.
2860
2861 e. Fixed a problem with revert-all-at-newline freeing freed memory.
2862
2863 f. Clarified the documentation for the history_quotes_inhibit_expansion
2864 variable to note that it inhibits scanning for the history comment
2865 character and that it only affects double-quoted strings.
2866
2867 g. Fixed an off-by-one error in the prompt printed when performing searches.
2868
2869 h. Use pselect(2), if available, to wait for input before calling read(2), so
2870 a SIGWINCH can interrupt it, since it doesn't interrupt read(2).
2871
2872 i. Some memory leaks caused by signals interrupting filename completion have
2873 been fixed.
2874
2875 j. Reading EOF twice on a non-empty line causes EOF to be returned, rather
2876 than the partial line. This can cause partial lines to be executed on
2877 SIGHUP, for example.
2878
2879 k. Fixed a bug concerning deleting multibyte characters from the search
2880 string while performing an incremental search.
2881
2882 l. Fixed a bug with tilde expanding directory names in filename completion.
2883
2884 m. Fixed a bug that did not allow binding sequences beginning with a `\'.
2885
2886 n. Fixed a redisplay bug involving incorrect line wrapping when the prompt
2887 contains a multibyte character in the last screen column.
2888
2889 o. Fixed a bug that caused history expansion to disregard characters that are
2890 documented to delimit a history event specifier without requiring `:'.
2891
2892 p. Fixed a bug that could cause reading past the end of a string when reading
2893 the value when binding the set of isearch terminators.
2894
2895 q. Fixed a bug that caused readline commands that depend on knowing which
2896 key invoked them to misbehave when dispatching key sequences that are
2897 prefixes of other key bindings.
2898
2899 r. Paren matching now works in vi insert mode.
2900
2901 3. New Features in Bash
2902
2903 a. There is now a settable configuration #define that will cause the shell
2904 to exit if the shell is running setuid without the -p option and setuid
2905 to the real uid fails.
2906
2907 b. Command and process substitutions now turn off the `-v' option when
2908 executing, as other shells seem to do.
2909
2910 c. The default value for the `checkhash' shell option may now be set at
2911 compile time with a #define.
2912
2913 d. The `mapfile' builtin now has a -d option to use an arbitrary character
2914 as the record delimiter, and a -t option to strip the delimiter as
2915 supplied with -d.
2916
2917 e. The maximum number of nested recursive calls to `eval' is now settable in
2918 config-top.h; the default is no limit.
2919
2920 f. The `-p' option to declare and similar builtins will display attributes for
2921 named variables even when those variables have not been assigned values
2922 (which are technically unset).
2923
2924 g. The maximum number of nested recursive calls to `source' is now settable
2925 in config-top.h; the default is no limit.
2926
2927 h. All builtin commands recognize the `--help' option and print a usage
2928 summary.
2929
2930 i. Bash does not allow function names containing `/' and `=' to be exported.
2931
2932 j. The `ulimit' builtin has new -k (kqueues) and -P (pseudoterminals) options.
2933
2934 k. The shell now allows `time ; othercommand' to time null commands.
2935
2936 l. There is a new `--enable-function-import' configuration option to allow
2937 importing shell functions from the environment; import is enabled by
2938 default.
2939
2940 m. `printf -v var ""' will now set `var' to the empty string, as if `var=""'
2941 had been executed.
2942
2943 n. GLOBIGNORE, the pattern substitution word expansion, and programmable
2944 completion match filtering now honor the value of the `nocasematch' option.
2945
2946 o. There is a new ${parameter@spec} family of operators to transform the
2947 value of `parameter'.
2948
2949 p. Bash no longer attempts to perform compound assignment if a variable on the
2950 rhs of an assignment statement argument to `declare' has the form of a
2951 compound assignment (e.g., w='(word)' ; declare foo=$w); compound
2952 assignments are accepted if the variable was already declared as an array,
2953 but with a warning.
2954
2955 q. The declare builtin no longer displays array variables using the compound
2956 assignment syntax with quotes; that will generate warnings when re-used as
2957 input, and isn't necessary.
2958
2959 r. Executing the rhs of && and || will no longer cause the shell to fork if
2960 it's not necessary.
2961
2962 s. The `local' builtin takes a new argument: `-', which will cause it to save
2963 the single-letter shell options and restore their previous values at
2964 function return.
2965
2966 t. `complete' and `compgen' have a new `-o nosort' option, which forces
2967 readline to not sort the completion matches.
2968
2969 u. Bash now allows waiting for the most recent process substitution, since it
2970 appears as $!.
2971
2972 v. The `unset' builtin now unsets a scalar variable if it is subscripted with
2973 a `0', analogous to the ${var[0]} expansion.
2974
2975 w. `set -i' is no longer valid, as in other shells.
2976
2977 x. BASH_SUBSHELL is now updated for process substitution and group commands
2978 in pipelines, and is available with the same value when running any exit
2979 trap.
2980
2981 y. Bash now checks $INSIDE_EMACS as well as $EMACS when deciding whether or
2982 not bash is being run in a GNU Emacs shell window.
2983
2984 z. Bash now treats SIGINT received when running a non-builtin command in a
2985 loop the way it has traditionally treated running a builtin command:
2986 running any trap handler and breaking out of the loop.
2987
2988 aa. New variable: EXECIGNORE; a colon-separate list of patterns that will
2989 cause matching filenames to be ignored when searching for commands.
2990
2991 bb. Aliases whose value ends in a shell metacharacter now expand in a way to
2992 allow them to be `pasted' to the next token, which can potentially change
2993 the meaning of a command (e.g., turning `&' into `&&').
2994
2995 4. New Features in Readline
2996
2997 a. The history truncation code now uses the same error recovery mechanism as
2998 the history writing code, and restores the old version of the history file
2999 on error. The error recovery mechanism handles symlinked history files.
3000
3001 b. There is a new bindable variable, `enable-bracketed-paste', which enables
3002 support for a terminal's bracketed paste mode.
3003
3004 c. The editing mode indicators can now be strings and are user-settable
3005 (new `emacs-mode-string', `vi-cmd-mode-string' and `vi-ins-mode-string'
3006 variables). Mode strings can contain invisible character sequences.
3007 Setting mode strings to null strings restores the defaults.
3008
3009 d. Prompt expansion adds the mode string to the last line of a multi-line
3010 prompt (one with embedded newlines).
3011
3012 e. There is a new bindable variable, `colored-completion-prefix', which, if
3013 set, causes the common prefix of a set of possible completions to be
3014 displayed in color.
3015
3016 f. There is a new bindable command `vi-yank-pop', a vi-mode version of emacs-
3017 mode yank-pop.
3018
3019 g. The redisplay code underwent several efficiency improvements for multibyte
3020 locales.
3021
3022 h. The insert-char function attempts to batch-insert all pending typeahead
3023 that maps to self-insert, as long as it is coming from the terminal.
3024
3025 i. rl_callback_sigcleanup: a new application function that can clean up and
3026 unset any state set by readline's callback mode. Intended to be used
3027 after a signal.
3028
3029 ------------------------------------------------------------------------------
3030 This document details the changes between this version, bash-4.3-release, and
3031 the previous version, bash-4.3-rc2.
3032
3033 1. Changes to Bash
3034
3035 a. Only Posix-mode shells should exit on an assignment failure in the
3036 temporary environment preceding a special builtin. This is how it's been
3037 documented.
3038
3039 b. Fixed a bug that caused a failed special builtin to not exit a posix-mode
3040 shell if the failing builtin was on the LHS of a && or ||.
3041
3042 c. Changed the handling of unquoted backslashes in regular expressions to be
3043 closer to bash-4.2.
3044
3045 d. globstar (**) no longer traverses symbolic links that resolve to
3046 directories. This eliminates some duplicate entries.
3047
3048 e. Fixed a bug that caused a SIGCHLD trap handler to not be able to change the
3049 SIGCHLD disposition.
3050
3051 f. Fixed a bug that caused a crash when -x was enabled and a command
3052 contained a printable multibyte (wide) character.
3053
3054 g. Fixed a bug that caused an interactive shell without line editing enabled
3055 to read invalid data after receiving a SIGINT.
3056
3057 h. Fixed a bug that caused command word completion to fail if the directory in
3058 $PATH where the completion would be found contained single or double quotes.
3059
3060 i. Fixed a bug that caused a shell with -v enabled to print commands in $()
3061 multiple times.
3062
3063 2. Changes to Readline
3064
3065 a. Fixed a bug that caused `undo' to reference freed memory or null pointers.
3066
3067 3. New Features in Bash
3068
3069 a. The [[ -v ]] option now understands array references (foo[1]) and returns
3070 success if the referenced element has a value.
3071
3072 ------------------------------------------------------------------------------
3073 This document details the changes between this version, bash-4.3-rc2, and the
3074 previous version, bash-4.3-rc1.
3075
3076 1. Changes to Bash
3077
3078 a. Fixed a bug that left variables set by printf -v marked as invisible.
3079
3080 b. Fixed an off-by-one error in a job control warning message.
3081
3082 c. Fixed a bug that caused the shell to crash after declaring a nameref variable
3083 without a value.
3084
3085 d. Fixed a bug that caused asynchronous commands to not set $? correctly.
3086
3087 e. Fixed a bug that caused out-of-order execution when executing aliases with
3088 embedded newlines containing `.' commands.
3089
3090 f. Fixed a bug that caused error messages generated by expansion errors in
3091 `for' commands to have the wrong line number.
3092
3093 g. Fixed a bug that caused the `wait' builtin to not be interruptible in an
3094 interactive shell with job control enabled.
3095
3096 h. Fixed a bug that caused SIGINT and SIGQUIT to not be trappable in
3097 asynchronous subshell commands.
3098
3099 i. Bash now requires that the value assigned to a nameref variable be a valid
3100 shell identifier (variable name or array reference).
3101
3102 j. Converting an existing variable to a nameref variable now turns off the
3103 -i/-l/-u/-c attributes.
3104
3105 k. Displaying a nameref variable with `declare -p' now displays the nameref
3106 variable and its value rather than following the nameref chain.
3107
3108 l. Fixed a problem with interrupt handling that caused a second and subsequent
3109 SIGINT to be ignored by interactive shells.
3110
3111 m. Fixed a bug that caused certain positional parameter and array expansions
3112 to mishandle (discard) null positional parameters and array elements.
3113
3114 n. The shell no longer blocks receipt of signals while running trap handlers
3115 for those signals, and allows most trap handlers to be run recursively
3116 (running trap handlers while a trap handler is executing).
3117
3118 o. The shell now handles backslashes in regular expression arguments to the
3119 [[ command's =~ operator slightly differently, resulting in more
3120 consistent behavior.
3121
3122 2. Changes to Readline
3123
3124 a. Fixed a bug that could cause readline to crash and seg fault attempting to
3125 expand an empty history entry.
3126
3127 b. Fixed a bug that caused a bad entry in the $LS_COLORS variable to abort all
3128 color processing but leave color enabled.
3129
3130 c. Fixed a bug that caused display problems with multi-line prompts containing
3131 invisible characters on multiple lines.
3132
3133 d. Fixed a bug that caused effects made by undoing changes to a history line to
3134 be discarded.
3135
3136 3. New Features in Bash
3137
3138 4. New Features in Readline
3139
3140 a. When creating shared libraries on Mac OS X, the pathname written into the
3141 library (install_name) no longer includes the minor version number.
3142 ------------------------------------------------------------------------------
3143 This document details the changes between this version, bash-4.3-rc1, and the
3144 previous version, bash-4.3-beta2.
3145
3146 1. Changes to Bash
3147
3148 a. Fixed a bug in bash completion that caused a tilde to be expanded even if
3149 the `direxpand' option was not enabled.
3150
3151 b. Fixed a potential bug that could cause corrupted input in interactive shells
3152 running without line editing and with `ignoreeof' enabled.
3153
3154 c. Fixed a bug that could cause failures when opening pipes back to shells
3155 created to run process substitutions.
3156
3157 d. Fixed a bug that caused an assignment to TEXTDOMAIN to require TEXTDOMAINDIR
3158 to be set in order to actually change the current text domain.
3159
3160 e. Changed the way redirections are printed to avoid confusion when the target
3161 of an output redirection is a process substitution beginning with `>'.
3162
3163 2. Changes to Readline
3164
3165 a. Shared library building is now supported on Mac OS X 10.9 (Darwin 13).
3166
3167 3. New Features in Bash
3168
3169 a. `cd' has a new `-@' option to browse a file's extended attributes on
3170 systems that support O_XATTR.
3171
3172 4. New Features in Readline
3173
3174 a. There are additional default key bindings for MinGW32
3175
3176 ------------------------------------------------------------------------------
3177 This document details the changes between this version, bash-4.3-beta2, and the
3178 previous version, bash-4.3-beta.
3179
3180 1. Changes to Bash
3181
3182 a. Fixed a bug that caused assignment to an unset variable using a negative
3183 subscript to result in a segmentation fault.
3184
3185 b. Fixed a bug that caused assignment to a string variable using a negative
3186 subscript to use the incorrect index.
3187
3188 c. Fixed a bug that caused some strings to be interpreted as invalid
3189 extended globbing expressions when used with the help builtin.
3190
3191 d. Fixed a bug that caused an attempt to trap a signal whose disposition
3192 cannot be changed to reference uninitialized memory.
3193
3194 e. Command completion now skips assignment statements preceding a command
3195 name and completes the command.
3196
3197 f. Fixed a bug that caused `compgen -f' in a non-interactive shell to dump
3198 core under certain circumstances.
3199
3200 g. Fixed a bug that caused the `read -N' to misbehave when the input stream
3201 contains 0xff.
3202
3203 2. Changes to Readline
3204
3205 a. Changed message when an incremental search fails to include "failed" in
3206 the prompt and display the entire search string instead of just the last
3207 matching portion.
3208
3209 b. Fixed a bug that caused an arrow key typed to an incremental search prompt
3210 to process the key sequence incorrectly.
3211
3212 c. Additional key bindings for arrow keys on MinGW.
3213
3214 3. New Features in Bash
3215
3216 a. The help builtin now attempts substring matching (as it did through
3217 bash-4.2) if exact string matching fails.
3218
3219 b. The fc builtin now interprets -0 as the current command line.
3220
3221 c. Completing directory names containing shell variables now adds a trailing
3222 slash if the expanded result is a directory.
3223
3224 4. New Features in Readline
3225
3226 a. rl_change_environment: new application-settable variable that controls
3227 whether or not Readline modifies the environment (currently readline
3228 modifies only LINES and COLUMNS).
3229
3230 ------------------------------------------------------------------------------
3231 This document details the changes between this version, bash-4.3-beta, and the
3232 previous version, bash-4.3-alpha.
3233
3234 1. Changes to Bash
3235
3236 a. Fixed a bug in the prompt directory name "trimming" code that caused
3237 memory corruption and garbled the results.
3238
3239 b. Fixed a bug that caused single quotes that resulted from $'...' quoting
3240 in the replacement portion of a double-quoted ${word/pat/rep} expansion
3241 to be treated as quote characters.
3242
3243 c. Fixed a bug that caused assignment statements preceding a command word to
3244 result in assignment statements following a declaration command to not be
3245 expanded like assignment statements.
3246
3247 d. Fixed a bug with variable search order in the presence of local variables
3248 with the same name as variables in the temporary environment supplied to
3249 a shell function.
3250
3251 e. Fixed a bug that caused constructs like 1<(2) to be interpreted as process
3252 substitutions even in an arithmetic context.
3253
3254 f. Fixed several cases where `invisible' variables (variables with attributes
3255 but no values, which are technically unset) were treated incorrectly.
3256
3257 g. Fixed a bug that caused group commands in pipelines that were not the
3258 last element to not run the EXIT trap.
3259
3260 h. Fixed a bug that caused `unset -n' to not unset a nameref variable in
3261 certain cases.
3262
3263 i. Fixed the nameref circular reference checking to be less strict and only
3264 disallow a nameref variable with the same value as its name at the global
3265 scope.
3266
3267 j. Fixed a bug that caused trap handlers to be executed recursively,
3268 corrupting internal data structures.
3269
3270 k. Fixed a bug that could result in bash not compiling if certain options were
3271 not enabled.
3272
3273 l. Fixed a bug that caused the arithmetic expansion code to attempt variable
3274 assignments when operator precedence prohibited them.
3275
3276 m. Word expansions like ${foo##bar} now understand indirect variable references.
3277
3278 n. Fixed a bug that caused `declare -fp name' to not display a function
3279 definition.
3280
3281 o. Fixed a bug that caused asynchronous child processes to modify the stdin
3282 file pointer when bash was using it to read a script, which modified the
3283 parent's value as well.
3284
3285 2. Changes to Readline
3286
3287 a. Fixed a bug in vi mode that caused the arrow keys to set the saved last
3288 vi-mode command to the wrong value.
3289
3290 b. Fixed a bug that caused double-quoted strings to be scanned incorrectly
3291 when being used as the value of a readline variable assignment.
3292
3293 c. Fixed a bug with vi mode that prevented `.' from repeating a command
3294 entered on a previous line (command).
3295
3296 d. Fixed a bug that could cause completion to core dump if it was interrupted
3297 by a signal.
3298
3299 e. Readline now sends the meta-key enable string to the terminal if the
3300 terminal has been successfully initialized.
3301
3302 f. Readline now calls the signal hook after resizing the terminal when it
3303 receives a SIGWINCH.
3304
3305 g. Fixed a bug that could cause the history list code to perform an out-of-
3306 bounds array reference if the history list is empty.
3307
3308 3. New Features in Bash
3309
3310 a. Shells started to run process substitutions now run any trap set on EXIT.
3311
3312 b. There is now a configure-time option to enable the globasciiranges option
3313 by default.
3314
3315 c. The read builtin now checks its first variable argument for validity before
3316 trying to read any input.
3317
3318 ------------------------------------------------------------------------------
3319 This document details the changes between this version, bash-4.3-alpha,
3320 and the previous version, bash-4.2-release.
3321
3322 1. Changes to Bash
3323
3324 a. Fixed several bugs concerning incomplete bracket expressions in filename
3325 generation (globbing) patterns.
3326
3327 b. Fixed a bug with single quotes and WORD in ${param op WORD} when running
3328 in Posix mode.
3329
3330 c. Fixed a bug that caused the pattern removal and pattern substitution word
3331 expansions and case statement word expansion to not match the empty string.
3332
3333 d. Fixed a bug that caused the tzset() function to not work after changing
3334 the TZ environment variable.
3335
3336 e. Fixed a bug that caused the RHS of an assignment statement to undergo
3337 word splitting when it contained an unquoted $@.
3338
3339 f. Fixed bugs that caused the shell to not react to a SIGINT sent while
3340 waiting for a child process to exit.
3341
3342 g. Bash doesn't try to run things in a signal handler context when it gets a
3343 signal (SIGINT/SIGHUP/etc) while reading input using readline but still
3344 be responsive to terminating signals.
3345
3346 h. Fixed a bug that caused bash to go into an infinite loop if a filename
3347 to be matched contained an invalid multibyte character.
3348
3349 i. Fixed a bug that caused PS4 to end up being truncated if it is longer
3350 than 128 bytes.
3351
3352 j. Fixed a bug that caused brace expansion to not skip over double-quoted
3353 command substitution.
3354
3355 k. System-specific updates for: DJGPP, HP/UX, Mac OS X
3356
3357 l. Fixed a bug in displaying commands that caused redirections to be associated
3358 with the wrong part of the command.
3359
3360 m. Fixed the coproc cleanup to unset the appropriate shell variables when a
3361 coproc terminates.
3362
3363 n. Fixed a bug that caused `fc' to dump core due to incorrect calculation of
3364 the last history entry.
3365
3366 o. Added workarounds for FreeBSD's implementation of faccessat/eaccess and
3367 `test -x'.
3368
3369 p. Fixed a bug that caused the shell to not match patterns containing
3370 control-A.
3371
3372 q. Fixed a bug that could result in doubled error messages when the `printf'
3373 builtin got a write error.
3374
3375 r. Fixed a bug that caused the shell to not correctly expand words containing
3376 multiple consecutive quoted empty strings (""""""aa).
3377
3378 s. Fixed a bug that caused the shell to not correctly parse multi-line
3379 process substitutions containing comments and quoted strings.
3380
3381 t. Fixed a problem with the bash malloc's internal idea of the top of the
3382 memory heap that resulted in incorrect decisions to try to reduce the
3383 break and give memory back to the kernel.
3384
3385 u. There are changes to the expansions performed on compound array assignments,
3386 in an effort to make foo=( [ind1]=bar [ind2]=baz ) identical to
3387 foo[ind1]=bar foo[ind2]=baz.
3388
3389 v. Bash now reports an error if `read -a name' is used when `name' is an
3390 existing associative array.
3391
3392 w. Fixed a bug that allowed an attempted assignment to a readonly variable
3393 in an arithmetic expression to not return failure.
3394
3395 x. Fixed several bugs that caused completion functions to be invoked even when
3396 the cursor was before the first word in the command.
3397
3398 y. Fixed a bug that caused parsing a command substitution to overwrite the
3399 parsing state associated with the complete input line.
3400
3401 z. Fixed several bugs with the built-in snprintf replacement and field widths
3402 and floating point.
3403
3404 aa. Fixed a bug that caused incorrect offset calculations and input buffer
3405 corruption when reading files longer than 2^31 bytes.
3406
3407 bb. Fixed several bugs where bash performed arithmetic evaluation in contexts
3408 where evaluation is suppressed.
3409
3410 cc. Fixed a bug that caused bash to close FIFOs used for process substitution
3411 too early when a shell function was executing, but protect against using
3412 all file descriptors when the shell functions are invoked inside loops.
3413
3414 dd. Added checks for printable (and non-printable) multibyte characters for
3415 use in error messages.
3416
3417 ee. Fixed a bug that caused ^O (operate-and-get-next) to not work correctly
3418 at the end of the history list.
3419
3420 ff. Fixed a bug that caused command-oriented history to incorrectly combine
3421 here documents into one line.
3422
3423 gg. Fixed a bug that caused importing SHELLOPTS from the environment into a
3424 Posix-mode shell to print an error message and refuse to parse it.
3425
3426 hh. Fixed a bug that caused the shell to delete an extra history entry when
3427 using `history -s'.
3428
3429 ii. Fixed a bug that caused floating-point exceptions and overflow errors
3430 for the / and % arithmetic operators when using INTMAX_MIN and -1.
3431
3432 jj. Fixed a bug that caused parsing errors when reading an arithmetic for
3433 loop inside a command substitution.
3434
3435 kk. Fixed a bug that caused a readonly function to be unset when unset was
3436 called without the -f or -v option.
3437
3438 ll. Fixed several bugs in the code that quotes characters special to regular
3439 expressions when used in a quoted string on the RHS of the =~ operator
3440 to the [[ command.
3441
3442 mm. Fixed a bug that caused redirections to fail because the file descriptor
3443 limit was set to a value less than 10.
3444
3445 nn. Fixed a bug that caused the `read' builtin to execute code in a signal
3446 handler context if read timed out.
3447
3448 oo. Fixed a bug that caused extended globbing patterns to not match files
3449 beginning with `.' correctly when a `.' was explicitly supplied in the
3450 pattern.
3451
3452 pp. Fixed a bug that caused key sequences longer than two characters to not
3453 work when used with `bind -x'.
3454
3455 qq. Fixed a bug that resulted in redefined functions having the wrong source
3456 file names in BASH_SOURCE.
3457
3458 rr. Fixed a bug that caused the read builtin to assign null strings to variables
3459 when using `read -N', which caused core dumps when referenced
3460
3461 ss. Fixed a bug that caused `bash -m script' to not enable job control while
3462 running the script.
3463
3464 tt. Fixed a bug that caused `printf -v var' to dump core when used with the
3465 %b format code.
3466
3467 uu. Fixed a bug that caused the shell to exit with the wrong status if -e was
3468 active and the shell exited on a substitution error.
3469
3470 vv. Fixed a bug that caused the shell to seg fault if an array variable with
3471 the same name as an existing associative array was implicitly created by
3472 an assignment (declare a[n]=b).
3473
3474 ww. Fixed a bug that caused a redirection to misbehave if the number specified
3475 for a file descriptor overflows an intmax_t.
3476
3477 xx. Fixed several bugs with the handling of valid and invalid unicode character
3478 values when used with the \u and \U escape sequences to printf and $'...'.
3479
3480 yy. Fixed a bug that caused tildes to not be escaped in expanded filenames,
3481 making them subject to later expansion.
3482
3483 zz. When using the pattern substitution word expansion, bash now runs the
3484 replacement string through quote removal, since it allows quotes in that
3485 string to act as escape characters. This is not backwards compatible, so
3486 it can be disabled by setting the bash compatibility mode to 4.2.
3487
3488 aaa. Fixed the rest of the cases where the shell runs non-allowed code in a
3489 signal handler context.
3490
3491 bbb. Fixed a bug that caused spurious DEL characters (\177) to appear in
3492 double-quoted expansion where the RHS is evaluated to the empty string.
3493
3494 ccc. Fixed a bug that caused the use of the shell's internal random number
3495 generator for temporary file names to perturb the random number
3496 sequence.
3497
3498 ddd. Fixed several bugs that caused `declare -g' to not set the right global
3499 variables or to misbehave when declaring global indexed arrays.
3500
3501 eee. Fixed a logic bug that caused extended globbing in a multibyte locale to
3502 cause failures when using the pattern substititution word expansions.
3503
3504 fff. Fixed a bug that caused the `lastpipe' option to corrupt the file
3505 descriptor used to read the script.
3506
3507 ggg. Fixed a bug that causes the shell to delete DEL characters in the
3508 expanded value of variables used in the same quoted string as variables
3509 that expand to nothing.
3510
3511 hhh. Fixed a bug that caused the shell to assign the wrong value from an
3512 assignment like (( x=7 )) when `x' was an existing array variable.
3513
3514 iii. Fixed a bug that caused the shell to misbehave when generating sequences
3515 and the boundary values overflow an intmax_t.
3516
3517 jjj. Fixed a bug caused expansion errors if an expansion of "$@" appeared
3518 next to another expansion (e.g.. "${@}${x}").
3519
3520 kkk. Fixed a potential buffer overflow bug when performing /dev/fd expansion.
3521
3522 lll. Fixed a bug that resulted in an extra semicolon being added to compound
3523 assignments when they were added to the history list.
3524
3525 mmm. Fixed a bug that caused mapfile to read one extra line from the input.
3526
3527 nnn. Fixed a bug that caused the mail checking code to use uninitialized
3528 values.
3529
3530 ooo. Fixed a bug that prevented history timestamps from being saved if the
3531 history comment character is unset.
3532
3533 ppp. Fixed a bug that caused the case-modifying expansions to not work with
3534 multibyte characters.
3535
3536 qqq. Fixed a bug that caused the edit-and-execute bindable readline command
3537 to see the wrong data if invoked in the middle of a multi-line quoted
3538 string.
3539
3540 rrr. Fixed a bug that resulted in the shell returning the wrong exit status
3541 for a background command on systems that recycle PIDs very quickly.
3542
3543 sss. Fixed a bug that caused asynchronous group commands to not run any EXIT
3544 trap defined in the body of the command.
3545
3546 ttt. Fixed a bug that caused `eval "... ; return"' to not clean up properly.
3547
3548 uuu. Fixed a bug that caused the shell to dump core if `read' reads an escaped
3549 IFS whitespace character.
3550
3551 vvv. Fixed a bug that caused BASH_COMMAND to be set to an incorrect value when
3552 executing a (...) subshell.
3553
3554 www. Fixed a couple of pointer aliasing bugs with the token string in arithmetic
3555 evaluation.
3556
3557 xxx. Fixed a bug with parsing multi-line command substitutions when reading
3558 the `do' keyword followed by whitespace.
3559
3560 yyy. Fixed a bug that caused the shell to seg fault if the time given to the
3561 printf %(...)T format overflowed the value accepted by localtime(3).
3562
3563 zzz. Fixed a problem with displaying help topics in two columns when the
3564 translated text contained multibyte characters.
3565
3566 aaaa. Fixed a bug with the extended globbing pattern matcher where a `*' was
3567 followed by a negated extended glob pattern.
3568
3569 bbbb. Fixed a race condition with short-lived coproc creation and reaping that
3570 caused the child process to be reaped before the various coproc shell
3571 variables were initialized.
3572
3573 cccc. Fixed a bug where turning off `errexit' in command substitution subshells
3574 was not reflected in $SHELLOPTS.
3575
3576 dddd. Partially fixed an inconsistency in how the shell treated shell
3577 functions run from an EXIT trap.
3578
3579 eeee. Fixed a bug in how the shell invalidated FIFOs used for process
3580 substitution when executing a pipeline (once rather than in every child).
3581
3582 ffff. Fixed a bug that occurred when expanding a special variable ($@, $*)
3583 within double quotes and the expansion resulted in an empty string.
3584
3585 gggg. Fixed bugs with executing a SIGCHLD trap handler to make sure that it's
3586 executed once per exited child.
3587
3588 hhhh. Fixed a bug that caused `declare' and `test' to find variables that
3589 had been given attributes but not assigned values. Such variables are
3590 not set.
3591
3592 iiii. Fixed a bug that caused commands in process substitutions to not look in
3593 the local temporary environment when performing word expansions.
3594
3595 jjjj. Fixed several problems with globstar expansions (**/**) returning null
3596 filenames and multiple instances of the same pathname.
3597
3598 kkkk. Fixed an oversight that did not allow the exit status of `coproc' to
3599 be inverted using `!'.
3600
3601 llll. Fixed a bug that caused the -e option to be re-enabled using `set -e'
3602 even when executing in a context where -e is ignored.
3603
3604 mmmm. Fixed a (mostly theoretical) bug with input lines longer than SIZE_MAX.
3605
3606 nnnn. Fixed a bug that could result in double evaluation of command
3607 substitutions when they appear in failed redirections.
3608
3609 oooo. Fixed a bug that could cause seg faults during `mapfile' callbacks if
3610 the callback unsets the array variable mapfile is using.
3611
3612 pppp. Fixed several problems with variable assignments using ${var:=value}
3613 when the variable assignment is supposed to have side effects.
3614
3615 qqqq. Fixed a bug that caused a failure of an assignment statement preceding a
3616 builtin caused the next invocation of a special builtin to exit the shell.
3617
3618 rrrr. Fixed several problems with IFS when it appears in the temporary environment
3619 and is used in redirections.
3620
3621 ssss. Fixed a problem that caused IFS changes using ${IFS:=value} to modify
3622 how preceding expansions were split.
3623
3624 tttt. Fixed a problem that caused subshells to not run an EXIT trap they set.
3625
3626 uuuu. Fixed a problem that caused shells started in posix mode to attempt to
3627 import shell functions with invalid names from the environment. We now
3628 print a warning.
3629
3630 vvvv. Worked around a kernel problem that caused SIGCHLD to interrupt open(2)
3631 on a FIFO used for process substitution, even if the SIGCHLD handler was
3632 installed with the SA_RESTART flag.
3633
3634 wwww. Fixed a problem that resulted in inconsistent expansion of $* and ${a[*]}.
3635
3636 xxxx. Fixed a problem that caused `read -t' to crash when interrupted by
3637 SIGINT.
3638
3639 yyyy. Fixed a problem that caused pattern removal to fail randomly because the
3640 pattern matcher read beyond the end of a string.
3641
3642 zzzz. Fixed a bug that caused core dumps when shell functions tried to create
3643 local shadow copies of special variables like GROUPS.
3644
3645 aaaaa. Fixed a bug that caused SIGTERM to be occasionally lost by children of
3646 interactive shells when it arrived before the child process reset the
3647 handler from SIG_DFL.
3648
3649 bbbbb. Fixed a bug that caused redirections like <&n- to leave file descriptor
3650 n closed if executed with a builtin command.
3651
3652 ccccc. Fixed a bug that caused incorrect completion quoting when completing a
3653 word containing a globbing character with `show-all-if-ambiguous' set.
3654
3655 ddddd. Fixed a bug that caused printf's %q format specifier not to quote a
3656 tilde even if it appeared in a location where it would be subject to
3657 tilde expansion.
3658
3659 2. Changes to Readline
3660
3661 a. Fixed a bug that did not allow the `dd', `cc', or `yy' vi editing mode
3662 commands to work on the entire line.
3663
3664 b. Fixed a bug that caused redisplay problems with prompts longer than 128
3665 characters and history searches.
3666
3667 c. Fixed a bug that caused readline to try and run code to modify its idea
3668 of the screen size in a signal handler context upon receiving a SIGWINCH.
3669
3670 d. Fixed a bug that caused the `meta' key to be enabled beyond the duration
3671 of an individual call top readline().
3672
3673 e. Added a workaround for a wcwidth bug in Mac OS X that caused readline's
3674 redisplay to mishandle zero-width combining characters.
3675
3676 f. Fixed a bug that caused readline to `forget' part of a key sequence when
3677 a multiple-key sequence caused it to break out of an incremental search.
3678
3679 g. Fixed bugs that caused readline to execute code in a signal handler
3680 context if interrupted while reading from the file system during completion.
3681
3682 h. Fixed a bug that caused readline to `forget' part of a key sequence when
3683 reading an unbound multi-character key sequence.
3684
3685 i. Fixed a bug that caused Readline's signal handlers to be installed beyond
3686 the bounds of a single call to readline().
3687
3688 j. Fixed a bug that caused the `.' command to not redo the most recent `R'
3689 command in vi mode.
3690
3691 k. Fixed a bug that caused ignoring case in completion matches to result in
3692 readline using the wrong match.
3693
3694 l. Paren matching now works in vi insert mode.
3695
3696 m. Fix menu-completion to make show-all-if-ambiguous and menu-complete-display-prefix
3697 work together.
3698
3699 n. Fixed a bug that didn't allow the `cc', `dd', or `yy' commands to be redone
3700 in vi editing mode.
3701
3702 o. Fixed a bug that caused the filename comparison code to not compare
3703 multibyte characters correctly when using case-sensitive or case-mapping
3704 comparisons.
3705
3706 p. Fixed the input reading loop to call the input hook function only when there
3707 is no terminal input available.
3708
3709 q. Fixed a bug that caused binding a macro to a multi-character key sequence
3710 where the sequence and macro value share a common prefix to not perform
3711 the macro replacement.
3712
3713 r. Fixed several redisplay errors with multibyte characters and prompts
3714 containing invisible characters when using horizontal scrolling.
3715
3716 s. Fixed a bug that caused redisplay errors when trying to overwrite
3717 existing characters using multibyte characters.
3718
3719 3. New Features in Bash
3720
3721 a. The `helptopic' completion action now maps to all the help topics, not just
3722 the shell builtins.
3723
3724 b. The `help' builtin no longer does prefix substring matching, so `help read'
3725 does not match `readonly'.
3726
3727 c. The shell can be compiled to not display a message about processes that
3728 terminate due to SIGTERM.
3729
3730 d. Non-interactive shells now react to the setting of checkwinsize and set
3731 LINES and COLUMNS after a foreground job exits.
3732
3733 e. There is a new shell option, `globasciiranges', which, when set to on,
3734 forces globbing range comparisons to use character ordering as if they
3735 were run in the C locale.
3736
3737 f. There is a new shell option, `direxpand', which makes filename completion
3738 expand variables in directory names in the way bash-4.1 did.
3739
3740 g. In Posix mode, the `command' builtin does not change whether or not a
3741 builtin it shadows is treated as an assignment builtin.
3742
3743 h. The `return' and `exit' builtins accept negative exit status arguments.
3744
3745 i. The word completion code checks whether or not a filename containing a
3746 shell variable expands to a directory name and appends `/' to the word
3747 as appropriate. The same code expands shell variables in command names
3748 when performing command completion.
3749
3750 j. In Posix mode, it is now an error to attempt to define a shell function
3751 with the same name as a Posix special builtin.
3752
3753 k. When compiled for strict Posix conformance, history expansion is disabled
3754 by default.
3755
3756 l. The history expansion character (!) does not cause history expansion when
3757 followed by the closing quote in a double-quoted string.
3758
3759 m. `complete' and its siblings compgen/compopt now takes a new `-o noquote'
3760 option to inhibit quoting of the completions.
3761
3762 n. Setting HISTSIZE to a value less than zero causes the history list to be
3763 unlimited (setting it 0 zero disables the history list).
3764
3765 o. Setting HISTFILESIZE to a value less than zero causes the history file size
3766 to be unlimited (setting it to 0 causes the history file to be truncated
3767 to zero size).
3768
3769 p. The `read' builtin now skips NUL bytes in the input.
3770
3771 q. There is a new `bind -X' option to print all key sequences bound to Unix
3772 commands.
3773
3774 r. When in Posix mode, `read' is interruptible by a trapped signal. After
3775 running the trap handler, read returns 128+signal and throws away any
3776 partially-read input.
3777
3778 s. The command completion code skips whitespace and assignment statements
3779 before looking for the command name word to be completed.
3780
3781 t. The build process has a new mechanism for constructing separate help files
3782 that better reflects the current set of compilation options.
3783
3784 u. The -nt and -ot options to test now work with files with nanosecond
3785 timestamp resolution.
3786
3787 v. The shell saves the command history in any shell for which history is
3788 enabled and HISTFILE is set, not just interactive shells.
3789
3790 w. The shell has `nameref' variables and new -n(/+n) options to declare and
3791 unset to use them, and a `test -R' option to test for them.
3792
3793 x. The shell now allows assigning, referencing, and unsetting elements of
3794 indexed arrays using negative subscripts (a[-1]=2, echo ${a[-1]}) which
3795 count back from the last element of the array.
3796
3797 y. The {x}<word redirection feature now allows words like {array[ind]} and
3798 can use variables with special meanings to the shell (e.g., BASH_XTRACEFD).
3799
3800 z. There is a new CHILD_MAX special shell variable; its value controls the
3801 number of exited child statuses the shell remembers.
3802
3803 aa. There is a new configuration option (--enable-direxpand-default) that
3804 causes the `direxpand' shell option to be enabled by default.
3805
3806 bb. Bash does not do anything special to ensure that the file descriptor
3807 assigned to X in {x}<foo remains open after the block containing it
3808 completes.
3809
3810 cc. The `wait' builtin has a new `-n' option to wait for the next child to
3811 change status.
3812
3813 dd. The `printf' %(...)T format specifier now uses the current time if no
3814 argument is supplied.
3815
3816 ee. There is a new variable, BASH_COMPAT, that controls the current shell
3817 compatibility level.
3818
3819 ff. The `popd' builtin now treats additional arguments as errors.
3820
3821 gg. The brace expansion code now treats a failed sequence expansion as a
3822 simple string and will continue to expand brace terms in the remainder
3823 of the word.
3824
3825 4. New Features in Readline
3826
3827 a. Readline is now more responsive to SIGHUP and other fatal signals when
3828 reading input from the terminal or performing word completion but no
3829 longer attempts to run any not-allowable functions from a signal handler
3830 context.
3831
3832 b. There are new bindable commands to search the history for the string of
3833 characters between the beginning of the line and the point
3834 (history-substring-search-forward, history-substring-search-backward)
3835
3836 c. Readline allows quoted strings as the values of variables when setting
3837 them with `set'. As a side effect, trailing spaces and tabs are ignored
3838 when setting a string variable's value.
3839
3840 d. The history library creates a backup of the history file when writing it
3841 and restores the backup on a write error.
3842
3843 e. New application-settable variable: rl_filename_stat_hook: a function called
3844 with a filename before using it in a call to stat(2). Bash uses it to
3845 expand shell variables so things like $HOME/Downloads have a slash
3846 appended.
3847
3848 f. New bindable function `print-last-kbd-macro', prints the most-recently-
3849 defined keyboard macro in a reusable format.
3850
3851 g. New user-settable variable `colored-stats', enables use of colored text
3852 to denote file types when displaying possible completions (colored analog
3853 of visible-stats).
3854
3855 h. New user-settable variable `keyseq-timout', acts as an inter-character
3856 timeout when reading input or incremental search strings.
3857
3858 i. New application-callable function: rl_clear_history. Clears the history list
3859 and frees all readline-associated private data.
3860
3861 j. New user-settable variable, show-mode-in-prompt, adds a characters to the
3862 beginning of the prompt indicating the current editing mode.
3863
3864 k. New application-settable variable: rl_input_available_hook; function to be
3865 called when readline needs to check whether there is data available on its
3866 input source. The default hook checks rl_instream.
3867
3868 l. Readline calls an application-set event hook (rl_signal_event_hook) after
3869 it gets a signal while reading input (read returns -1/EINTR but readline
3870 does not handle the signal immediately) to allow the application to handle
3871 or otherwise note it. Not currently called for SIGHUP or SIGTERM.
3872
3873 m. If the user-settable variable `history-size' is set to a value less than
3874 0, the history list size is unlimited.
3875
3876 ------------------------------------------------------------------------------
3877 This document details the changes between this version, bash-4.2-release,
3878 and the previous version, bash-4.2-rc2.
3879
3880 1. Changes to Bash
3881
3882 a. Fixed a bug that caused some variables to be clobbered by a longjmp,
3883 resulting in stack corruption.
3884
3885 ------------------------------------------------------------------------------
3886 This document details the changes between this version, bash-4.2-rc2,
3887 and the previous version, bash-4.2-rc1.
3888
3889 1. Changes to Bash
3890
3891 a. Changes to bash_directory_completion_hook so that it's assigned to the
3892 readline rl_directory_rewrite_hook variable, which modifies the directory
3893 name passed to opendir without modifying the directory name the user
3894 typed.
3895
3896 b. Fixed bug in select builtin that caused it to not terminate correctly if
3897 the read timed out due to $TMOUT.
3898
3899 c. Fixed a problem that resulted in non-repeatable sequences of random
3900 numbers when RANDOM=0.
3901
3902 ------------------------------------------------------------------------------
3903 This document details the changes between this version, bash-4.2-rc1,
3904 and the previous version, bash-4.2-beta.
3905
3906 1. Changes to Bash
3907
3908 a. Fixed a bug that caused some redirection errors to leak file descriptors.
3909
3910 b. Fixed a bug that caused unary `+' and `-' arithmetic operators to have a
3911 higher precedence than unary `!' and `~'.
3912
3913 c. Fixed a bug that caused simple commands in a pipeline to affect the exit
3914 status ($?) seen by subsequent pipeline commands.
3915
3916 d. A number of cygwin-specific changes to avoid the use of text-mode files
3917 and file access, and to make sure that \r is handled correctly.
3918
3919 e. Fixed a bug that caused the read builtin to not return failure if an
3920 attempt is made to assign to a readonly variable.
3921
3922 f. Fixed a bug that caused some builtin usage messages to not be translated.
3923
3924 g. Fixed a bug that caused the getopts builtin to not return failure if an
3925 attempt is made to assign to a readonly variable. Now it returns 2.
3926
3927 h. Fixed the cd and pwd builtins to return failure if PWD is readonly and
3928 cannot be assigned to.
3929
3930 i. Added code to check the return value of access(2) on Solaris systems,
3931 since it returns success for executable tests (e.g., `test -x') when
3932 run by root, even if the file permissions don't allow execution.
3933
3934 2. Changes to Readline
3935
3936 a. Fixed a bug that caused directory names in words to be completed to not
3937 be dequoted correctly.
3938
3939 3. New Features in Bash
3940
3941 4. New Features in Readline
3942
3943 ------------------------------------------------------------------------------
3944 This document details the changes between this version, bash-4.2-beta,
3945 and the previous version, bash-4.2-alpha.
3946
3947 1. Changes to Bash
3948
3949 a. Fixed a bug that caused the \W prompt string escape to not add a closing
3950 NULL.
3951
3952 b. Fixed a bug that caused partially-quoted words that were not subject to
3953 word splitting to retained quoted NULLs.
3954
3955 c. Added considerable efficiency speedups when pattern matching in multibyte
3956 locales by skipping multibyte character functions where possible.
3957
3958 d. Added considerable speedups to variable expansion when in multibyte locales.
3959
3960 e. Fixed a bug that caused the expansion of $* when there are no positional
3961 parameters to cause the shell to dump core when used in a pattern
3962 matching context.
3963
3964 f. Fixed a bug that caused variable expansions preceding regular builtins to
3965 not change the shell environment during their execution.
3966
3967 2. Changes to Readline
3968
3969 a. Fixed a bug that made an explicit argument of 0 to yank-last-arg behave
3970 as if it were a negative argument.
3971
3972 ------------------------------------------------------------------------------
3973 This document details the changes between this version, bash-4.2-alpha,
3974 and the previous version, bash-4.1-release.
3975
3976 1. Changes to Bash
3977
3978 a. Fixed a bug in the parser when processing alias expansions containing
3979 quoted newlines.
3980
3981 b. Fixed a memory leak in associative array expansion.
3982
3983 c. Fixed a bug that caused quoted here-strings to be requoted when printed.
3984
3985 d. Fixed a bug in arithmetic expansion that caused the index in an array
3986 expansion to be evaluated twice under certain circumstances.
3987
3988 e. Fixed several bugs with the expansion and display of variables that have
3989 been given attributes but not values and are technically unset.
3990
3991 f. Fixed a bug that caused core dumps when using filename completion that
3992 expands to a filename containing a globbing character.
3993
3994 g. Fixed a bug that caused assignment statements preceding a special builtin
3995 when running in Posix mode to not persist after the builtin completed
3996 when the special builtin was executed in a shell function without any
3997 local variables.
3998
3999 h. Fixed a bug that caused a command to remain in the hash table even after
4000 `hash command' did not find anything if there was already an existing
4001 hashed pathname.
4002
4003 i. Fixed several bugs caused by executing unsafe functions from a signal
4004 handler in the cases where a signal handler is executed immediately
4005 rather than setting a flag for later execution.
4006
4007 j. Fixed a bug that caused some internal flag variables to be set
4008 incorrectly if `read -t' timed out.
4009
4010 k. Fixed a Posix compatibility issue by making sure that a backslash escaping
4011 a `}' within a double-quoted ${...} parameter expansion is removed as part
4012 of the parameter expansion.
4013
4014 l. Fixed a bug that caused execution of a trap to overwrite PIPESTATUS.
4015
4016 m. Fixed a bug that caused here documents to not be displayed correctly
4017 when attached to commands inside compound commands.
4018
4019 n. Fixed a bug that caused the printf builtin to use the wrong precision
4020 when using the `*' modifier.
4021
4022 o. Fixed a bug that caused an arriving SIGCHLD to interrupt output functions
4023 like those invoked by echo or printf.
4024
4025 p. Changed to use a more robust mechanism than eaccess(2) when test is
4026 checking filenames for execution permission.
4027
4028 q. Fixed a bug that caused spurious semicolons to be added into the command
4029 history in certain cases.
4030
4031 r. Fixed a bug that caused the shell to free non-allocated memory when
4032 unsetting element 0 of an associative array after it was assigned
4033 implicitly.
4034
4035 s. Fixed a bug that could cause the shell to dump core if using the `v'
4036 vi editing command on a multi-line command.
4037
4038 t. Fixed a bug that left FIFOs opened by process substitutions open long
4039 enough to potentially cause file descriptor exhaustion when running a
4040 shell function or shell builtin.
4041
4042 u. Fixed a bug that caused the history expansion functions to not recognize
4043 process substitution or extended glob patterns as single words.
4044
4045 v. Fixed a bug that caused restricted shells to set a restricted command's
4046 exit status incorrectly.
4047
4048 w. Fixed a bug that caused bash to ignore the wrong set of filenames when
4049 completing a command using the `complete-filename' readline command.
4050
4051 x. Fixed a bug that caused a -PID argument following a -s sig or -n sig to
4052 not be interpreted as a signal specification.
4053
4054 y. Changed posix-mode behavior of a parse error in a `.' script or `eval'
4055 command to exit the shell under Posix-specified conditions. Previous
4056 versions printed a warning.
4057
4058 z. Fixed a bug in \W prompt expansion that resulted in incorrect expansion
4059 in the event of overlapping strings.
4060
4061 aa. Fixed a bug that caused the := parameter expansion operator to return the
4062 wrong value as the result of the expansion.
4063
4064 bb. When in Posix mode, a single quote is not treated specially in a
4065 double-quoted ${...} expansion, unless the expansion operator is
4066 # or % or the non-Posix `//', `^', and `,'. In particular, it does
4067 not define a new quoting context. This is from Posix interpretation 221.
4068
4069 cc. Fixed a bug that inadvertently allowed program names containing slashes
4070 to be entered into the command hash table.
4071
4072 dd. Fixed a bug that caused the select builtin to incorrectly compute the
4073 display width of the arguments in the presence of multibyte characters.
4074
4075 ee. Fixed a bug that caused bash to not change the xtrace file descriptor if
4076 BASH_XTRACEFD was found in the shell environment at startup.
4077
4078 ff. Fixed a memory leak in the pattern removal parameter expansion.
4079
4080 gg. Fixed a bug that caused SIGINT to fail to interrupt a nested loop if the
4081 loop was in a pipeline.
4082
4083 hh. Fixed a problem in $(...) parsing that caused the parser to add an extra
4084 space to a here-document delimiter if the first word contained a `/'.
4085
4086 ii. Fixed a bug that caused functions defined with the `function' reserved
4087 word to require braces around the function body.
4088
4089 jj. Fixed a bug that caused bash to dump core when a variable expansion being
4090 used as an array subscript failed.
4091
4092 kk. Fixed a bug that caused bash to dump core if the case-modification
4093 expansions were used on a variable with a null value.
4094
4095 ll. Fixed a bug that caused partially-quoted strings to be split incorrectly
4096 if a variable with a null value was expanded within double quotes.
4097
4098 mm. The pattern substitution word expansion has been sped up dramatically
4099 when running in a locale with multibyte characters.
4100
4101 nn. Fixed a bug that caused history -a to not write the correct lines to
4102 the history file if all the new lines in the history list were added
4103 since the last time the history file was read or written.
4104
4105 oo. Fixed a bug that caused completion of a word with an unclosed `` command
4106 substitution to set the prompt incorrectly.
4107
4108 pp. Fixed a bug that caused extended globbing patterns in $HISTIGNORE or
4109 $GLOBIGNORE to be incorrectly scanned.
4110
4111 qq. Fixed a bug caused by closing file descriptors 3-20 on shell startup. The
4112 shell now sets them to close-on-exec.
4113
4114 rr. Fixed a bug that caused the exit status of `exec file' to be set incorrectly
4115 if `file' was a directory.
4116
4117 ss. Fixed a bug in the `.' builtin to make a non-interactive posix-mode shell
4118 exit if the file argument to `.' is not found. Prefixing exec with
4119 `command' makes the shell not exit. Posix requires this behavior.
4120
4121 tt. Fixed a bug that caused `sh -c 'command exec; exit 1' to hang.
4122
4123 uu. Fixed a bug in $(...) command substitution parsing that caused the shell
4124 to treat backslash-newline incorrectly when parsing a comment.
4125
4126 vv. Fixed bug that caused brace expansion sequence generation to misbehave
4127 when supplied integers greater than 2**31 - 1.
4128
4129 ww. Fixed a bug that caused failure to save file descriptors for redirections
4130 to corrupt shell file descriptors.
4131
4132 xx. Fixed a bug that caused bash-forward-shellword to not correctly handle
4133 quoted strings.
4134
4135 2. Changes to Readline
4136
4137 a. Fixed a bug that caused the unconverted filename to be added to the list of
4138 completions when the application specified filename conversion functions.
4139
4140 b. Fixed a bug that caused the wrong filename to be passed to opendir when the
4141 application has specified a filename dequoting function.
4142
4143 c. Fixed a bug when repeating a character search in vi mode in the case where
4144 there was no search to repeat.
4145
4146 d. When show-all-if-ambiguous is set, the completion routines no longer insert
4147 a common match prefix that is shorter than the text being completed.
4148
4149 e. The full set of vi editing commands may now be used in callback mode.
4150
4151 f. Fixed a bug that caused readline to not update its idea of the terminal
4152 dimensions while running in `no-echo' mode.
4153
4154 h. Fixed a bug that caused readline to dump core if an application called
4155 rl_prep_terminal without setting rl_instream.
4156
4157 i. Fixed a bug that caused meta-prefixed characters bound to incremental
4158 search forward or backward to not be recognized if they were typed
4159 subsequently.
4160
4161 j. The incremental search code treats key sequences that map to the same
4162 functions as (default) ^G, ^W, and ^Y as equivalent to those characters.
4163
4164 k. Fixed a bug in menu-complete that caused it to misbehave with large
4165 negative argument.
4166
4167 l. Fixed a bug that caused vi-mode yank-last-arg to ring the bell when invoked
4168 at the end of the line.
4169
4170 3. New Features in Bash
4171
4172 a. `exec -a foo' now sets $0 to `foo' in an executable shell script without a
4173 leading #!.
4174
4175 b. Subshells begun to execute command substitutions or run shell functions or
4176 builtins in subshells do not reset trap strings until a new trap is
4177 specified. This allows $(trap) to display the caller's traps and the
4178 trap strings to persist until a new trap is set.
4179
4180 c. `trap -p' will now show signals ignored at shell startup, though their
4181 disposition still cannot be modified.
4182
4183 d. $'...', echo, and printf understand \uXXXX and \UXXXXXXXX escape sequences.
4184
4185 e. declare/typeset has a new `-g' option, which creates variables in the
4186 global scope even when run in a shell function.
4187
4188 f. test/[/[[ have a new -v variable unary operator, which returns success if
4189 `variable' has been set.
4190
4191 g. Posix parsing changes to allow `! time command' and multiple consecutive
4192 instances of `!' (which toggle) and `time' (which have no cumulative
4193 effect).
4194
4195 h. Posix change to allow `time' as a command by itself to print the elapsed
4196 user, system, and real times for the shell and its children.
4197
4198 j. $((...)) is always parsed as an arithmetic expansion first, instead of as
4199 a potential nested command substitution, as Posix requires.
4200
4201 k. A new FUNCNEST variable to allow the user to control the maximum shell
4202 function nesting (recursive execution) level.
4203
4204 l. The mapfile builtin now supplies a third argument to the callback command:
4205 the line about to be assigned to the supplied array index.
4206
4207 m. The printf builtin has a new %(fmt)T specifier, which allows time values
4208 to use strftime-like formatting.
4209
4210 n. There is a new `compat41' shell option.
4211
4212 o. The cd builtin has a new Posix-mandated `-e' option.
4213
4214 p. Negative subscripts to indexed arrays, previously errors, now are treated
4215 as offsets from the maximum assigned index + 1.
4216
4217 q. Negative length specifications in the ${var:offset:length} expansion,
4218 previously errors, are now treated as offsets from the end of the variable.
4219
4220 r. Parsing change to allow `time -p --'.
4221
4222 s. Posix-mode parsing change to not recognize `time' as a keyword if the
4223 following token begins with a `-'. This means no more Posix-mode
4224 `time -p'. Posix interpretation 267.
4225
4226 t. There is a new `lastpipe' shell option that runs the last command of a
4227 pipeline in the current shell context. The lastpipe option has no
4228 effect if job control is enabled.
4229
4230 u. History expansion no longer expands the `$!' variable expansion.
4231
4232 v. Posix mode shells no longer exit if a variable assignment error occurs
4233 with an assignment preceding a command that is not a special builtin.
4234
4235 w. Non-interactive mode shells exit if -u is enabled and an attempt is made
4236 to use an unset variable with the % or # expansions, the `//', `^', or
4237 `,' expansions, or the parameter length expansion.
4238
4239 x. Posix-mode shells use the argument passed to `.' as-is if a $PATH search
4240 fails, effectively searching the current directory. Posix-2008 change.
4241
4242 4. New Features in Readline
4243
4244 a. The history library does not try to write the history filename in the
4245 current directory if $HOME is unset. This closes a potential security
4246 problem if the application does not specify a history filename.
4247
4248 b. New bindable variable `completion-display-width' to set the number of
4249 columns used when displaying completions.
4250
4251 c. New bindable variable `completion-case-map' to cause case-insensitive
4252 completion to treat `-' and `_' as identical.
4253
4254 d. There are new bindable vi-mode command names to avoid readline's case-
4255 insensitive matching not allowing them to be bound separately.
4256
4257 e. New bindable variable `menu-complete-display-prefix' causes the menu
4258 completion code to display the common prefix of the possible completions
4259 before cycling through the list, instead of after.
4260
4261 ------------------------------------------------------------------------------
4262 This document details the changes between this version, bash-4.1-rc,
4263 and the previous version, bash-4.1-beta.
4264
4265 1. Changes to Bash
4266
4267 a. Fixed a bug that caused printf to not return a partial value when it
4268 encountered an error while converting an integer argument.
4269
4270 b. Fixed a bug that caused setting one of the compatNN options to not
4271 turn off the others.
4272
4273 c. The (undocumented) --wordexp option is no longer included by default.
4274
4275 d. Fixed a bug in conditional command execution that caused it to not
4276 correctly ignore the exit status under certain circumstances.
4277
4278 e. Added a configure-time check for correctly-working asprintf/snprintf.
4279
4280 f. Fixed some problems with line number calculation and display when sourcing
4281 a file in an interactive shell.
4282
4283 g. Fixed a bug that caused the shell to crash when using `declare -A foo=bar'.
4284
4285 h. Fixed a bug that caused an off-by-one error when calculating the directories
4286 to display with the PROMPT_DIRTRIM option.
4287
4288 2. Changes to Readline
4289
4290 a. Fixed a bug that caused applications using the callback interface to not
4291 react to SIGINT (or other signals) until another character arrived.
4292
4293 ------------------------------------------------------------------------------
4294 This document details the changes between this version, bash-4.1-beta,
4295 and the previous version, bash-4.1-alpha.
4296
4297 1. Changes to Bash
4298
4299 a. Fixed a bug in mapfile that caused the shell to crash if it was passed the
4300 name of an associative array.
4301
4302 b. Fixed a bug that caused the shell to incorrectly split case patterns if
4303 they contained characters in $IFS.
4304
4305 c. Fixed a bug that caused the shell to set $? to the wrong value when using
4306 a construct ending with a variable assignment with set -x enabled and PS4
4307 containing a command substitution.
4308
4309 d. Fixed a bug that caused the shell to read commands incorrectly if an
4310 expansion error occurred under certain conditions in a user-specified
4311 subshell.
4312
4313 e. Fixed a bug that caused the shell to set $? incorrectly if a parse error
4314 occurred in an evaluation context ("eval", trap command, dot script, etc.)
4315
4316 f. Fixed a bug that caused the shell to attempt command substitution
4317 completion within a single-quoted string.
4318
4319 g. Fixed a bug that caused the shell to insert an extra single quote during
4320 word completion.
4321
4322 h. Fixed a bug that caused the shell to crash if invoked with the environment
4323 variable EMACS having a null value.
4324
4325 i. Fixed a bug that caused bash to incorrectly report the presence of new
4326 mail in a `maildir' environment.
4327
4328 j. Fixed a bug that caused the shell to not recognize a here-document ending
4329 delimiter inside a command substitution.
4330
4331 k. Fixed a bug that caused the shell to crash when a a dynamic array variable
4332 was assigned a scalar value.
4333
4334 2. Changes to Readline
4335
4336 3. New Features in Bash
4337
4338 a. The mapfile/readarray builtin no longer stores the commands it invokes via
4339 callbacks in the history list.
4340
4341 b. There is a new `compat40' shopt option.
4342
4343 c. The < and > operators to [[ do string comparisons using the current locale
4344 only if the compatibility level is greater than 40 (set to 41 by default).
4345
4346 4. New Features in Readline
4347
4348 ------------------------------------------------------------------------------
4349 This document details the changes between this version, bash-4.1-alpha,
4350 and the previous version, bash-4.0-release.
4351
4352 1. Changes to Bash
4353
4354 a. Fixed bugs in the parser involving new parsing of the commands contained
4355 in command substitution when the substitution is read.
4356
4357 b. Fixed a bug that caused the shell to dump core when performing programmable
4358 completion using a shell function.
4359
4360 c. Fixed a bug in `mapfile' that caused it to invoke callbacks at the wrong
4361 time.
4362
4363 d. Fixed a bug that caused the shell to dump core when listing jobs in the
4364 `exit' builtin.
4365
4366 e. Fixed several bugs encountered when reading subscripts in associative
4367 array assignments and expansions.
4368
4369 f. Fixed a bug that under some circumstances caused an associative array to
4370 be converted to an indexed array.
4371
4372 g. Fixed a bug that caused syntax errors and SIGINT interrupts to not set
4373 $? to a value > 128.
4374
4375 h. Fixed a bug that caused the shell to remove FIFOs associated with process
4376 substitution inside shell functions.
4377
4378 i. Fixed a bug that caused terminal attributes to not be reset when the
4379 `read' builtin timed out.
4380
4381 j. Fixed a bug in brace expansion that caused unwanted zero padding of the
4382 expanded terms.
4383
4384 k. Fixed a bug that prevented the |& construct from working as intended when
4385 used with a simple command with additional redirections.
4386
4387 l. Fixed a bug with the case statement ;& terminator that caused the shell to
4388 dereference a NULL pointer.
4389
4390 m. Fixed a bug that caused assignment statements or redirections preceding
4391 a simple command name to inhibit alias expansion.
4392
4393 n. Fixed the behavior of `set -u' to conform to the latest Posix interpretation:
4394 every expansion of an unset variable except $@ and $* will cause the
4395 shell to exit.
4396
4397 o. Fixed a bug that caused double-quoted expansions of $* inside word
4398 expansions like ${x#$*} to not expand properly when $IFS is empty.
4399
4400 p. Fixed a bug that caused traps to set $LINENO to the wrong value when they
4401 execute.
4402
4403 q. Fixed a bug that caused off-by-one errors when computing history lines in
4404 the `fc' builtin.
4405
4406 r. Fixed a bug that caused some terminating signals to not exit the shell
4407 quickly enough, forcing the kernel to send the signal (e.g., SIGSEGV)
4408 multiple times.
4409
4410 s. Fixed a bug that caused the shell to attempt to add empty lines to the
4411 history list when reading here documents.
4412
4413 t. Made some internal changes that dramatically speeds up sequential indexed
4414 array access.
4415
4416 u. Fixed a bug that caused the shell to write past the end of a string when
4417 completing a double-quoted string ending in a backslash.
4418
4419 v. Fixed a bug that caused the shell to replace too many characters when a
4420 pattern match was null in a ${foo//bar} expansion.
4421
4422 w. Fixed bugs in the expansion of ** that caused duplicate directory names
4423 and the contents of the current directory to be omitted.
4424
4425 x. Fixed a bug that caused $? to not be set correctly when referencing an
4426 unset variable with set -u and set -e enabled.
4427
4428 y. Fixed a bug caused by executing an external program from the DEBUG trap
4429 while a pipeline was running. The effect was to disturb the pipeline
4430 state, occasionally causing it to hang.
4431
4432 z. Fixed a bug that caused the ** glob expansion to dump core if it
4433 encountered an unsearchable directory.
4434
4435 aa. Fixed a bug that caused `command -v' and `command -V' to not honor the
4436 path set by the -p option.
4437
4438 bb. Fixed a bug that caused brace expansion to take place too soon in some
4439 compound array assignments.
4440
4441 cc. Fixed a bug that caused programmable completion functions' changes to
4442 READLINE_POINT to not be reflected back to readline.
4443
4444 dd. Fixed a bug that caused the shell to dump core if a trap was executed
4445 during a shell assignment statement.
4446
4447 ee. Fixed an off-by-one error when computing the number of positional
4448 parameters for the ${@:0:n} expansion.
4449
4450 ff. Fixed a problem with setting COMP_CWORD for programmable completion
4451 functions that could leave it set to -1.
4452
4453 gg. Fixed a bug that caused the ERR trap to be triggered in some cases where
4454 `set -e' would not have caused the shell to exit.
4455
4456 hh. Fixed a bug that caused changes made by `compopt' to not persist past the
4457 completion function in which compopt was executed.
4458
4459 ii. Fixed a bug that caused the list of hostname completions to not be cleared
4460 when HOSTNAME was unset.
4461
4462 jj. Fixed a bug that caused variable expansion in here documents to look in
4463 any temporary environment.
4464
4465 kk. Bash and readline can now convert file names between precomposed and
4466 decomposed Unicode on Mac OS X ("keyboard" and file system forms,
4467 respectively). This affects filename completion (using new
4468 rl_filename_rewrite_hook), globbing, and readline redisplay.
4469
4470 ll. The ERR and EXIT traps now see a non-zero value for $? when a parser
4471 error after set -e has been enabled causes the shell to exit.
4472
4473 mm. Fixed a bug that in brace expansion that caused zero-prefixed terms to
4474 not contain the correct number of digits.
4475
4476 nn. Fixed a bug that caused the shell to free non-allocated memory when
4477 unsetting an associative array which had had a value implicitly assigned
4478 to index "0".
4479
4480 oo. Fixed a memory leak in the ${!prefix@} expansion.
4481
4482 pp. Fixed a bug that caused printf to not correctly report all write errors.
4483
4484 qq. Fixed a bug that caused single and double quotes to act as delimiters
4485 when splitting a command line into words for programmable completion.
4486
4487 rr. Fixed a bug that caused ** globbing that caused **/path/* to match every
4488 directory, not just those matching `path'.
4489
4490 ss. Fixed a bug that caused the shell to dump core when running `help' without
4491 arguments if the terminal width was fewer than 7 characters.
4492
4493 2. Changes to Readline
4494
4495 a. The SIGWINCH signal handler now avoids calling the redisplay code if
4496 one arrives while in the middle of redisplay.
4497
4498 b. Changes to the timeout code to make sure that timeout values greater
4499 than one second are handled better.
4500
4501 c. Fixed a bug in the redisplay code that was triggered by a prompt
4502 containing invisible characters exactly the width of the screen.
4503
4504 d. Fixed a bug in the redisplay code encountered when running in horizontal
4505 scroll mode.
4506
4507 e. Fixed a bug that prevented menu completion from properly completing
4508 filenames.
4509
4510 f. Fixed a redisplay bug caused by a multibyte character causing a line to
4511 wrap.
4512
4513 g. Fixed a bug that caused key sequences of two characters to not be
4514 recognized when a longer sequence identical in the first two characters
4515 was bound.
4516
4517 h. Fixed a bug that caused history expansion to be attempted on $'...'
4518 single-quoted strings.
4519
4520 i. Fixed a bug that caused incorrect redisplay when the prompt contained
4521 multibyte characters in an `invisible' sequence bracketed by \[ and
4522 \].
4523
4524 j. Fixed a bug that caused history expansion to short-circuit after
4525 encountering a multibyte character.
4526
4527 3. New Features in Bash
4528
4529 a. Here-documents within $(...) command substitutions may once more be
4530 delimited by the closing right paren, instead of requiring a newline.
4531
4532 b. Bash's file status checks (executable, readable, etc.) now take file
4533 system ACLs into account on file systems that support them.
4534
4535 c. Bash now passes environment variables with names that are not valid
4536 shell variable names through into the environment passed to child
4537 processes.
4538
4539 d. The `execute-unix-command' readline function now attempts to clear and
4540 reuse the current line rather than move to a new one after the command
4541 executes.
4542
4543 e. `printf -v' can now assign values to array indices.
4544
4545 f. New `complete -E' and `compopt -E' options that work on the "empty"
4546 completion: completion attempted on an empty command line.
4547
4548 g. New complete/compgen/compopt -D option to define a `default' completion:
4549 a completion to be invoked on command for which no completion has been
4550 defined. If this function returns 124, programmable completion is
4551 attempted again, allowing a user to dynamically build a set of completions
4552 as completion is attempted by having the default completion function
4553 install individual completion functions each time it is invoked.
4554
4555 h. When displaying associative arrays, subscripts are now quoted.
4556
4557 i. Changes to dabbrev-expand to make it more `emacs-like': no space appended
4558 after matches, completions are not sorted, and most recent history entries
4559 are presented first.
4560
4561 j. The [[ and (( commands are now subject to the setting of `set -e' and the
4562 ERR trap.
4563
4564 k. The source/. builtin now removes NUL bytes from the file before attempting
4565 to parse commands.
4566
4567 l. There is a new configuration option (in config-top.h) that forces bash to
4568 forward all history entries to syslog.
4569
4570 m. A new variable $BASHOPTS to export shell options settable using `shopt' to
4571 child processes.
4572
4573 n. There is a new configure option that forces the extglob option to be
4574 enabled by default.
4575
4576 o. New variable $BASH_XTRACEFD; when set to an integer bash will write xtrace
4577 output to that file descriptor.
4578
4579 p. If the optional left-hand-side of a redirection is of the form {var}, the
4580 shell assigns the file descriptor used to $var or uses $var as the file
4581 descriptor to move or close, depending on the redirection operator.
4582
4583 q. The < and > operators to the [[ conditional command now do string
4584 comparison according to the current locale.
4585
4586 r. Programmable completion now uses the completion for `b' instead of `a'
4587 when completion is attempted on a line like: a $(b c.
4588
4589 s. Force extglob on temporarily when parsing the pattern argument to
4590 the == and != operators to the [[ command, for compatibility.
4591
4592 t. Changed the behavior of interrupting the wait builtin when a SIGCHLD is
4593 received and a trap on SIGCHLD is set to be Posix-mode only.
4594
4595 u. The read builtin has a new `-N nchars' option, which reads exactly NCHARS
4596 characters, ignoring delimiters like newline.
4597
4598 4. New Features in Readline
4599
4600 a. New bindable function: menu-complete-backward.
4601
4602 b. In the vi insertion keymap, C-n is now bound to menu-complete by default,
4603 and C-p to menu-complete-backward.
4604
4605 c. When in vi command mode, repeatedly hitting ESC now does nothing, even
4606 when ESC introduces a bound key sequence. This is closer to how
4607 historical vi behaves.
4608
4609 d. New bindable function: skip-csi-sequence. Can be used as a default to
4610 consume key sequences generated by keys like Home and End without having
4611 to bind all keys.
4612
4613 e. New application-settable function: rl_filename_rewrite_hook. Can be used
4614 to rewrite or modify filenames read from the file system before they are
4615 compared to the word to be completed.
4616
4617 f. New bindable variable: skip-completed-text, active when completing in the
4618 middle of a word. If enabled, it means that characters in the completion
4619 that match characters in the remainder of the word are "skipped" rather
4620 than inserted into the line.
4621
4622 g. The pre-readline-6.0 version of menu completion is available as
4623 "old-menu-complete" for users who do not like the readline-6.0 version.
4624
4625 h. New bindable variable: echo-control-characters. If enabled, and the
4626 tty ECHOCTL bit is set, controls the echoing of characters corresponding
4627 to keyboard-generated signals.
4628
4629 i. New bindable variable: enable-meta-key. Controls whether or not readline
4630 sends the smm/rmm sequences if the terminal indicates it has a meta key
4631 that enables eight-bit characters.
4632
4633 ------------------------------------------------------------------------------
4634 This document details the changes between this version, bash-4.0-release,
4635 and the previous version, bash-4.0-rc1.
4636
4637 1. Changes to Bash
4638
4639 a. Changed the message printed when setlocale(3) fails to only include the
4640 strerror error text if the call changes errno.
4641
4642 b. Changed trap command execution to reset the line number before running a
4643 trap (except DEBUG and RETURN traps).
4644
4645 c. Fixed behavior of case-modifiying word expansions to not work on
4646 individual words within a variable's value.
4647
4648 d. Fixed a bug that caused mapfile to not be interruptible when run in an
4649 interactive shell.
4650
4651 e. Fixed a bug that caused mapfile to not run callbacks for the first line
4652 read.
4653
4654 f. Fixed a bug that caused mapfile to not honor EOF typed in an interactive
4655 shell.
4656
4657 g. Fixed the coprocess reaping code to not run straight from a signal handler.
4658
4659 h. Fixed a bug that caused printf -b to ignore the first % conversion specifier
4660 in the format string on 64-bit systems.
4661
4662 i. Fixed a bug that caused incorrect word splitting when `:', `=', or `~'
4663 appeared in $IFS.
4664
4665 j. Fixed a bug that caused data corruption in the programmable completion code
4666 when a shell function called from a completion aborted execution.
4667
4668 k. Fixed a bug that caused the CPU usage reported by the `time' builtin to be
4669 capped at 100%.
4670
4671 l. Changed behavior of shell when -e option is in effect to reflect consensus
4672 of Posix shell standardization working group.
4673
4674 m. Fixed a bug introduced in bash-4.0-alpha that caused redirections to not
4675 be displayed by `type' or `declare' when appearing in functions under
4676 certain circumstances.
4677
4678 2. Changes to Readline
4679
4680 a. Fixed a bug that caused !(...) extended glob patterns to inhibit later
4681 history expansion.
4682
4683 b. Reworked the signal handling to avoid calling disallowed functions from a
4684 signal handler.
4685
4686 3. New Features in Bash
4687
4688 a. `readarray' is now a synonym for `mapfile'.
4689 ------------------------------------------------------------------------------
4690 This document details the changes between this version, bash-4.0-rc1,
4691 and the previous version, bash-4.0-beta2.
4692
4693 1. Changes to Bash
4694
4695 a. Fixed a bug that caused parsing errors when a $()-style command
4696 substitution was followed immediately by a quoted newline.
4697
4698 b. Fixed a bug that caused extended shell globbing patterns beginning with
4699 `*(' to not work when used with pattern substitution word expansions.
4700
4701 ------------------------------------------------------------------------------
4702 This document details the changes between this version, bash-4.0-beta2,
4703 and the previous version, bash-4.0-beta.
4704
4705 1. Changes to Bash
4706
4707 a. Fixed a bug that caused failed word expansions to set $? but not
4708 PIPESTATUS.
4709
4710 b. Changed filename completion to quote the tilde in a filename with a
4711 leading tilde that exists in the current directory.
4712
4713 c. Fixed a bug that caused a file descriptor leak when performing
4714 redirections attached to a compound command.
4715
4716 d. Fixed a bug that caused expansions of $@ and $* to not exit the shell if
4717 the -u option was enabled and there were no posititional parameters.
4718
4719 e. Fixed a bug that resulted in bash not terminating immediately if a
4720 terminating signal was received while performing output.
4721
4722 f. Fixed a bug that caused the shell to crash after creating 256 process
4723 substitutions during word completion.
4724
4725 2. Changes to Readline
4726
4727 a. Fixed a bug that caused redisplay errors when using prompts with invisible
4728 characters and numeric arguments to a command in a multibyte locale.
4729
4730 b. Fixed a bug that caused redisplay errors when using prompts with invisible
4731 characters spanning more than two physical screen lines.
4732
4733 ------------------------------------------------------------------------------
4734 This document details the changes between this version, bash-4.0-beta,
4735 and the previous version, bash-4.0-alpha.
4736
4737 1. Changes to Bash
4738
4739 a. Fixed a typo that caused a variable to be used before initialization
4740 while parsing Posix-style command substitutions.
4741
4742 b. Fixed a bug that caused stray ^? when the expansion of a parameter used
4743 as part of a pattern removal expansion is empty, but part of a non-
4744 empty string.
4745
4746 c. Fixed a bug that could cause strings not converted to numbers by strtol
4747 to be treated as if the conversion had been successful.
4748
4749 d. The `return' builtin now accepts no options and requires a `--' before
4750 a negative return value, as Posix requires.
4751
4752 e. Fixed a bug that caused local variables to be created with the empty
4753 string for a value rather than no value.
4754
4755 f. Changed behavior so the shell now acts as if it received an interrupt
4756 when a pipeline is killed by SIGINT while executing a list.
4757
4758 g. Fixed a bug that caused `declare var' and `typeset var' to initialize
4759 `var' to the empty string.
4760
4761 h. Changed `bind' builtin to print a warning but proceed if invoked when
4762 line editing is not active.
4763
4764 i. Fixed a bug that caused the shell to exit when the `errexit' option is
4765 set and a command in a pipeline returns a non-zero exit status.
4766
4767 j. Fixed a bug that caused the shell to not run the exit trap in a command
4768 run with `bash -c' under some circumstances.
4769
4770 k. Fixed a bug that caused parser errors to occasionally not set $? when
4771 running commands with `eval'.
4772
4773 l. Fixed a bug that caused stray control characters when evaluating compound
4774 array assignments containing $'\x7f' escapes.
4775
4776 m. Fixed a bug that caused redirections involving file descriptor 10 as the
4777 target to behave incorrectly.
4778
4779 n. Fixed a bug that could cause memory to be freed multiple times when
4780 assigning to COMP_WORDBREAKS.
4781
4782 o. Fixed a bug that could cause NULL pointer dereferences when COMP_WORDBREAKS
4783 was unset.
4784
4785 2. Changes to Readline
4786
4787 3. New Features in Bash
4788
4789 a. A value of 0 for the -t option to `read' now returns success if there is
4790 input available to be read from the specified file descriptor.
4791
4792 b. CDPATH and GLOBIGNORE are ignored when the shell is running in privileged
4793 mode.
4794
4795 c. New bindable readline functions shell-forward-word and shell-backward-word,
4796 which move forward and backward words delimited by shell metacharacters
4797 and honor shell quoting.
4798
4799 d. New bindable readline functions shell-backward-kill-word and shell-kill-word
4800 which kill words backward and forward, but use the same word boundaries
4801 as shell-forward-word and shell-backward-word.
4802
4803 4. New Features in Readline
4804
4805 a. If the kernel supports it, readline displays special characters
4806 corresponding to a keyboard-generated signal when the signal is received.
4807
4808 ------------------------------------------------------------------------------
4809 This document details the changes between this version, bash-4.0-alpha,
4810 and the previous version, bash-3.2-release.
4811
4812 1. Changes to Bash
4813
4814 a. Fixed several bugs in old-style `` command substitution parsing, including
4815 comment parsing and quoted string handling.
4816
4817 b. Fixed problems parsing arguments to the [[ command's =~ regular expression
4818 matching operator: metacharacter and whitespace parsing.
4819
4820 c. Fixed a bug that caused the shell to inappropriately reuse high-numbered
4821 file descriptors it used internally.
4822
4823 d. Fixed a bug in pattern replacement word expansions that caused a `/' as
4824 the first character of an expanded pattern to be mistaken for a global
4825 replacement specifier.
4826
4827 e. Fixed several problems with the asprintf and snprintf replacement functions
4828 that caused hangs and crashes.
4829
4830 f. Fixed a bug in the calculation of the current and previous job that caused
4831 it to refer to incorrect jobs.
4832
4833 g. Fixed a bug in the check for the validity of a hashed command pathname that
4834 caused unnecessary hash table deletions and additions.
4835
4836 h. Fixed a bug that caused child processes to inherit the wrong value for $!.
4837
4838 i. Fixed a bug that caused `.' to fail to read and execute commands from non-
4839 regular files such as devices or named pipes.
4840
4841 j. Fixed a bug in printf formatting for the %x and %X expansions that occurred
4842 on some systems.
4843
4844 k. Fixed a bug that caused the shell to crash when creating temporary files if
4845 $TMPDIR named a non-writable directory.
4846
4847 l. Fixed a bug that caused the shell to ignore $TMPDIR when creating temporary
4848 files under some circumstances.
4849
4850 m. Fixed a bug that caused named pipes created by process substitution to not
4851 be cleaned up.
4852
4853 n. Fixed a bug that caused HISTTIMEFORMAT to not be honored when it appeared
4854 in the initial shell environment.
4855
4856 o. Fixed several bugs in the expansion of $* and $@ (quoted and unquoted)
4857 when IFS is null or contains non-whitespace characters; the same changes
4858 apply to arrays subscripted with * or @.
4859
4860 p. Fixed several problems with pattern substitution expansions on the
4861 positional parameters and arrays subscripted with * or @ that occurred
4862 when $IFS was set to the empty string.
4863
4864 q. Made a change to the default locale initialization code that should
4865 result in better behavior from the locale-aware library functions.
4866
4867 r. Fixed a bug that caused compacting the jobs list to drop jobs.
4868
4869 s. Fixed a bug that caused jumps back to the top-level processing loop from
4870 a builtin command to leave the shell in an inconsistent state.
4871
4872 t. Fixed a bug that caused characters that would be escaped internally to be
4873 doubled when escaped with a backslash.
4874
4875 u. Fixed the initialization of mailboxes to not cause maildirs to be read
4876 (and stat(2) called for every message file) at shell startup.
4877
4878 v. Fixed a bug that caused the shell to not display $PS2 when the read builtin
4879 reads a line continued with a backslash.
4880
4881 w. Fixed a bug that caused errors in word splitting when $IFS contained
4882 characters used for internal quoting.
4883
4884 x. Fixed bugs that caused problems with output from shell builtins not being
4885 completely displayed on some systems.
4886
4887 y. Fixed a bug that caused output to be lost when a redirection is acting on
4888 the shell's output file descriptor.
4889
4890 z. Fixed bugs caused by shell builtins not checking for all write errors.
4891
4892 aa. Fixed a problem that caused the shell to dump core if expansions on the
4893 pattern passed to the pattern removal word expansions resulted in expansion
4894 errors.
4895
4896 bb. Fixed a bug that caused bash to loop infinitely after creating and
4897 waiting for 4096 jobs.
4898
4899 cc. Fixed a bug that caused bash to lose the status of a background job under
4900 certain circumstances.
4901
4902 dd. Fixed a bug that caused bash to not look in the temporary environment
4903 when performing variable lookup under certain circumstances.
4904
4905 ee. Fixed a bug that caused bash to close file descriptors greater than 10
4906 when they were used in redirections.
4907
4908 ff. Fixed a problem that caused the shell to attempt to read from the standard
4909 input when called as `bash -i script'.
4910
4911 gg. Fixed a memory leak and variable initialization problems when the -v option
4912 was supplied to `printf' that could cause incorrect results.
4913
4914 hh. Fixed a bug that caused the `read' builtin to count bytes when the -n option
4915 was supplied, rather than (possibly multibyte) characters.
4916
4917 ii. Fixed a bug when displaying a function due to not converting the function
4918 to an external form.
4919
4920 jj. Changed job control initialization to ensure that the shell has a tty
4921 as its controlling terminal before enabling job control.
4922
4923 kk. Fixed a bug with the `test' builtin that caused it to misinterpret
4924 arguments beginning with `-' but containing more than one character.
4925
4926 ll. Fixed bug that could cause the shell to dump core in certain cases where
4927 a command sets the SIGINT disposition to the default.
4928
4929 mm. Fixed a bug in the pattern replacement (affecting both word expansion
4930 and the `fc' builtin) that occurred when the pattern and replacement
4931 strings were empty.
4932
4933 nn. Fixed a bug that caused an arithmetic evaluation error to disable all
4934 further evaluation.
4935
4936 oo. Fixed a bug in pathname expansion that caused it to interpret backslashes
4937 in the pathname as quoting characters.
4938
4939 pp. Fixed a bug in the replacement getcwd() implementation that could cause
4940 memory to be overwritten.
4941
4942 qq. When in Posix mode, the `ulimit' builtin now uses a block size of 512 for
4943 the `-c' and `-f' options.
4944
4945 rr. Brace expansion now allows process substitutions to pass through unchanged.
4946
4947 ss. Fixed a problem in the command name completion code to avoid quoting
4948 escaped special characters twice when the command name begins with a tilde.
4949
4950 tt. Fixed a problem in the printf builtin that resulted in single-byte
4951 output for the "'" escape, even when using multibyte characters.
4952
4953 uu. Fixed a bug that caused the failure exit status to be lost when redirections
4954 attached to a compound command failed.
4955
4956 vv. Fixed a bug that caused the internal random number generator to not be
4957 re-seeded correctly when creating a subshell.
4958
4959 ww. Fixed a bug that could cause the bash replacement getcwd to overwrite
4960 memory.
4961
4962 xx. Fixed a bug that caused the shell to not receive SIGINT if it was sent
4963 while the shell was waiting for a command substitution to terminate, and
4964 make sure the exit status is correct when it does.
4965
4966 yy. Fixed a bug that resulted in the second and subsequent children spawned
4967 by a shell begun to run a command substitution being placed into the
4968 wrong process group.
4969
4970 zz. Fixed a bug that caused the results of successful tilde expansion to be
4971 subject to pathname expansion and word splitting.
4972
4973 aaa. Fixed a bug that could cause the shell to hang if it encountered an
4974 error that caused it to jump back to the top processing loop during a
4975 command substitution or `eval' command.
4976
4977 bbb. Fixed a bug that caused the `read' builtin to use the tty's attributes
4978 instead of those of the file descriptor passed with the -u option when
4979 processing the -n and -d options.
4980
4981 ccc. Fixed a bug that caused incorrect expansion of ${array[@]:foo} if the
4982 first character of $IFS was not whitespace.
4983
4984 ddd. Fixed a bug that occurred when scanning for the ending delimiter of a
4985 ${parameter/pat/sub} expansion.
4986
4987 eee. Fixed a bug that caused the shell to inappropriately expand command
4988 substitutions in words when expanding directory names for completion.
4989
4990 fff. Fixed a bug that caused the `fc' builtin to look too far back in the
4991 history list under certain circumstances.
4992
4993 ggg. Fixed a bug that caused a shell running in Posix mode to search $PWD for
4994 a file specified as an argument to source/. when the file was not found
4995 in $PATH.
4996
4997 hhh. Fixed a bug that caused the shell to modify the case of a command word
4998 found via command completion when the shell was performing case-
4999 insensitive completion.
5000
5001 iii. Fixed a bug that caused the shell to search $PATH for an argument to
5002 source/. even when it contained a `/'.
5003
5004 jjj. Fixed a bug that caused brace expansion to misorder expansions when the
5005 locale did not have a collating order like aAbBcC...zZ.
5006
5007 kkk. Fixed a bug that did not allow `set +o history' to have any effect when
5008 run in a startup file or from a sourced file.
5009
5010 lll. Fixed a bug with the precedence of the ?: conditional arithmetic operator.
5011
5012 mmm. Fixed a bug that caused side effects of temporary variable assignments
5013 to persist in the shell environment.
5014
5015 nnn. Fixed a bug that caused the terminal to be left in non-canonical mode
5016 when using editing commands that invoke the an editor on the current
5017 command line.
5018
5019 ooo. Fixed a bug that caused globbing characters and characters in $IFS to not
5020 be quoted appropriately when displaying assignment statements.
5021
5022 ppp. Fixed a bug that caused the `-e' option to be inherited when sourcing a
5023 file or evaluating a command with `eval' even if the return value of the
5024 command was supposed to be ignored.
5025
5026 qqq. Fixed a bug that caused the shell to attempt to created variables with
5027 invalid names if such names appeared in the initial environment.
5028
5029 rrr. Fixed a bug with quote removal in strings where the final character is a
5030 backslash.
5031
5032 sss. Fixed a bug that caused the effects of special variables to persist even
5033 when the variables were unset as part of the shell reinitializing itself
5034 to execute a shell script.
5035
5036 ttt. Fixed a bug that caused the history to not be saved after `history -c' or
5037 `history -d' was executed until a sufficient number of commands had been
5038 saved to the history.
5039
5040 uuu. Bash now parses command substitutions according to Posix rules: parsing
5041 the command contained in $() to find the closing delimiter.
5042
5043 vvv. Fixed a bug that caused traps on SIGCHLD set in a SIGCHLD handler to
5044 not persist.
5045
5046 www. Fixed a bug that didn't allow SIGCHLD to interrupt the `wait' builtin
5047 as Posix specifies.
5048
5049 xxx. Invalid numeric arguments to shell builtins no longer cause the shell to
5050 short-circuit any executing compound command.
5051
5052 yyy. Fixed a bug that caused the exit status to be lost when `break' was
5053 used to short-circuit a loop's execution.
5054
5055 zzz. Fixed a bug that caused stray ^? characters to be left in expansions of
5056 "${array[*]}".
5057
5058 aaaa. Bash now prints better error messages for here documents terminated by
5059 EOF and for identifying the incorrect token in an invalid arithmetic
5060 expression.
5061
5062 bbbb. Fixed a bug in the variable length word expansion that caused it to
5063 incorrectly calculate the number of multibyte characters.
5064
5065 cccc. Fixed a race condition that could result in the top-level shell setting
5066 the terminal's process group to an incorrect value if the process
5067 group was changed by a child of a child of the shell.
5068
5069 dddd. Fixed a bug that caused here documents belonging to commands within a
5070 compound command to be displayed in a syntactially-incorrect form, which
5071 prevented them from being re-read as input.
5072
5073 eeee. The shell displays more warnings about failures to set the locale.
5074
5075 ffff. Fixed a bug that caused the body of a here-document to not be saved to
5076 the history list.
5077
5078 gggg. Fixed a bug that caused configure to incorrectly conclude that FreeBSD
5079 had /dev/fd available, resulting in problems with process substitution.
5080
5081 2. Changes to Readline
5082
5083 a. Fixed a number of redisplay errors in environments supporting multibyte
5084 characters.
5085
5086 b. Fixed bugs in vi command mode that caused motion commands to inappropriately
5087 set the mark.
5088
5089 c. When using the arrow keys in vi insertion mode, readline allows movement
5090 beyond the current end of the line (unlike command mode).
5091
5092 d. Fixed bugs that caused readline to loop when the terminal has been taken
5093 away and reads return -1/EIO.
5094
5095 e. Fixed bugs in redisplay occurring when displaying prompts containing
5096 invisible characters.
5097
5098 f. Fixed a bug that caused the completion append character to not be reset to
5099 the default after an application-specified completion function changed it.
5100
5101 g. Fixed a problem that caused incorrect positioning of the cursor while in
5102 emacs editing mode when moving forward at the end of a line while using
5103 a locale supporting multibyte characters.
5104
5105 h. Fixed an off-by-one error that caused readline to drop every 511th
5106 character of buffered input.
5107
5108 i. Fixed a bug that resulted in SIGTERM not being caught or cleaned up.
5109
5110 j. Fixed redisplay bugs caused by multiline prompts with invisible characters
5111 or no characters following the final newline.
5112
5113 k. Fixed redisplay bug caused by prompts consisting solely of invisible
5114 characters.
5115
5116 l. Fixed a bug in the code that buffers characters received very quickly in
5117 succession which caused characters to be dropped.
5118
5119 m. Fixed a bug that caused readline to reference uninitialized data structures
5120 if it received a SIGWINCH before completing initialization.
5121
5122 n. Fixed a bug that caused the vi-mode `last command' to be set incorrectly
5123 and therefore unrepeatable.
5124
5125 o. Fixed a bug that caused readline to disable echoing when it was being used
5126 with an output file descriptor that was not a terminal.
5127
5128 p. Readline now blocks SIGINT while manipulating internal data structures
5129 during redisplay.
5130
5131 q. Fixed a bug in redisplay that caused readline to segfault when pasting a
5132 very long line (over 130,000 characters).
5133
5134 r. Fixed bugs in redisplay when using prompts with no visible printing
5135 characters.
5136
5137 3. New Features in Bash
5138
5139 a. When using substring expansion on the positional parameters, a starting
5140 index of 0 now causes $0 to be prefixed to the list.
5141
5142 b. The `help' builtin now prints its columns with entries sorted vertically
5143 rather than horizontally.
5144
5145 c. There is a new variable, $BASHPID, which always returns the process id of
5146 the current shell.
5147
5148 d. There is a new `autocd' option that, when enabled, causes bash to attempt
5149 to `cd' to a directory name that is supplied as the first word of a
5150 simple command.
5151
5152 e. There is a new `checkjobs' option that causes the shell to check for and
5153 report any running or stopped jobs at exit.
5154
5155 f. The programmable completion code exports a new COMP_TYPE variable, set to
5156 a character describing the type of completion being attempted.
5157
5158 g. The programmable completion code exports a new COMP_KEY variable, set to
5159 the character that caused the completion to be invoked (e.g., TAB).
5160
5161 h. If creation of a child process fails due to insufficient resources, bash
5162 will try again several times before reporting failure.
5163
5164 i. The programmable completion code now uses the same set of characters as
5165 readline when breaking the command line into a list of words.
5166
5167 j. The block multiplier for the ulimit -c and -f options is now 512 when in
5168 Posix mode, as Posix specifies.
5169
5170 k. Changed the behavior of the read builtin to save any partial input received
5171 in the specified variable when the read builtin times out. This also
5172 results in variables specified as arguments to read to be set to the empty
5173 string when there is no input available. When the read builtin times out,
5174 it returns an exit status greater than 128.
5175
5176 l. The shell now has the notion of a `compatibility level', controlled by
5177 new variables settable by `shopt'. Setting this variable currently
5178 restores the bash-3.1 behavior when processing quoted strings on the rhs
5179 of the `=~' operator to the `[[' command.
5180
5181 m. The `ulimit' builtin now has new -b (socket buffer size) and -T (number
5182 of threads) options.
5183
5184 n. The -p option to `declare' now displays all variable values and attributes
5185 (or function values and attributes if used with -f).
5186
5187 o. There is a new `compopt' builtin that allows completion functions to modify
5188 completion options for existing completions or the completion currently
5189 being executed.
5190
5191 p. The `read' builtin has a new -i option which inserts text into the reply
5192 buffer when using readline.
5193
5194 q. A new `-E' option to the complete builtin allows control of the default
5195 behavior for completion on an empty line.
5196
5197 r. There is now limited support for completing command name words containing
5198 globbing characters.
5199
5200 s. Changed format of internal help documentation for all builtins to roughly
5201 follow man page format.
5202
5203 t. The `help' builtin now has a new -d option, to display a short description,
5204 and a -m option, to print help information in a man page-like format.
5205
5206 u. There is a new `mapfile' builtin to populate an array with lines from a
5207 given file.
5208
5209 v. If a command is not found, the shell attempts to execute a shell function
5210 named `command_not_found_handle', supplying the command words as the
5211 function arguments.
5212
5213 w. There is a new shell option: `globstar'. When enabled, the globbing code
5214 treats `**' specially -- it matches all directories (and files within
5215 them, when appropriate) recursively.
5216
5217 x. There is a new shell option: `dirspell'. When enabled, the filename
5218 completion code performs spelling correction on directory names during
5219 completion.
5220
5221 y. The `-t' option to the `read' builtin now supports fractional timeout
5222 values.
5223
5224 z. Brace expansion now allows zero-padding of expanded numeric values and
5225 will add the proper number of zeroes to make sure all values contain the
5226 same number of digits.
5227
5228 aa. There is a new bash-specific bindable readline function: `dabbrev-expand'.
5229 It uses menu completion on a set of words taken from the history list.
5230
5231 bb. The command assigned to a key sequence with `bind -x' now sets two new
5232 variables in the environment of the executed command: READLINE_LINE_BUFFER
5233 and READLINE_POINT. The command can change the current readline line
5234 and cursor position by modifying READLINE_LINE_BUFFER and READLINE_POINT,
5235 respectively.
5236
5237 cc. There is a new &>> redirection operator, which appends the standard output
5238 and standard error to the named file.
5239
5240 dd. The parser now understands `|&' as a synonym for `2>&1 |', which redirects
5241 the standard error for a command through a pipe.
5242
5243 ee. The new `;&' case statement action list terminator causes execution to
5244 continue with the action associated with the next pattern in the
5245 statement rather than terminating the command.
5246
5247 ff. The new `;;&' case statement action list terminator causes the shell to
5248 test the next set of patterns after completing execution of the current
5249 action, rather than terminating the command.
5250
5251 gg. The shell understands a new variable: PROMPT_DIRTRIM. When set to an
5252 integer value greater than zero, prompt expansion of \w and \W will
5253 retain only that number of trailing pathname components and replace
5254 the intervening characters with `...'.
5255
5256 hh. There are new case-modifying word expansions: uppercase (^[^]) and
5257 lowercase (,[,]). They can work on either the first character or
5258 array element, or globally. They accept an optional shell pattern
5259 that determines which characters to modify. There is an optionally-
5260 configured feature to include capitalization operators.
5261
5262 ii. The shell provides associative array variables, with the appropriate
5263 support to create, delete, assign values to, and expand them.
5264
5265 jj. The `declare' builtin now has new -l (convert value to lowercase upon
5266 assignment) and -u (convert value to uppercase upon assignment) options.
5267 There is an optionally-configurable -c option to capitalize a value at
5268 assignment.
5269
5270 kk. There is a new `coproc' reserved word that specifies a coprocess: an
5271 asynchronous command run with two pipes connected to the creating shell.
5272 Coprocs can be named. The input and output file descriptors and the
5273 PID of the coprocess are available to the calling shell in variables
5274 with coproc-specific names.
5275
5276 4. New Features in Readline
5277
5278 a. A new variable, rl_sort_completion_matches; allows applications to inhibit
5279 match list sorting (but beware: some things don't work right if
5280 applications do this).
5281
5282 b. A new variable, rl_completion_invoking_key; allows applications to discover
5283 the key that invoked rl_complete or rl_menu_complete.
5284
5285 c. The functions rl_block_sigint and rl_release_sigint are now public and
5286 available to calling applications who want to protect critical sections
5287 (like redisplay).
5288
5289 d. The functions rl_save_state and rl_restore_state are now public and
5290 available to calling applications; documented rest of readline's state
5291 flag values.
5292
5293 e. A new user-settable variable, `history-size', allows setting the maximum
5294 number of entries in the history list.
5295
5296 f. There is a new implementation of menu completion, with several improvements
5297 over the old; the most notable improvement is a better `completions
5298 browsing' mode.
5299
5300 g. The menu completion code now uses the rl_menu_completion_entry_function
5301 variable, allowing applications to provide their own menu completion
5302 generators.
5303
5304 h. There is support for replacing a prefix of a pathname with a `...' when
5305 displaying possible completions. This is controllable by setting the
5306 `completion-prefix-display-length' variable. Matches with a common prefix
5307 longer than this value have the common prefix replaced with `...'.
5308
5309 i. There is a new `revert-all-at-newline' variable. If enabled, readline will
5310 undo all outstanding changes to all history lines when `accept-line' is
5311 executed.
5312
5313 ------------------------------------------------------------------------------
5314 This document details the changes between this version, bash-3.2-release,
5315 and the previous version, bash-3.2-beta.
5316
5317 1. Changes to Bash
5318
5319 a. Fixed a bug that caused the temporary environment passed to a command to
5320 affect the shell's environment under certain circumstances.
5321
5322 b. Fixed a bug in the printf builtin that caused the %q format specifier to
5323 ignore empty string arguments.
5324
5325 c. Improved multibyte character environment detection at configuration time.
5326
5327 d. Fixed a bug in the read builtin that left spurious escape characters in the
5328 input after processing backslashes when assigning to an array variable.
5329
5330 2. Changes to Readline
5331
5332 a. Fixed a redisplay bug that occurred in multibyte-capable locales when the
5333 prompt was one character longer than the screen width.
5334 ------------------------------------------------------------------------------
5335 This document details the changes between this version, bash-3.2-beta,
5336 and the previous version, bash-3.2-alpha.
5337
5338 1. Changes to Bash
5339
5340 a. Changed the lexical analyzer to treat locale-specific blank characters as
5341 white space.
5342
5343 b. Fixed a bug in command printing to avoid confusion between redirections and
5344 process substitution.
5345
5346 c. Fixed problems with cross-compiling originating from inherited environment
5347 variables.
5348
5349 d. Added write error reporting to printf builtin.
5350
5351 e. Fixed a bug in the variable expansion code that could cause a core dump in
5352 a multi-byte locale.
5353
5354 f. Fixed a bug that caused substring expansion of a null string to return
5355 incorrect results.
5356
5357 g. BASH_COMMAND now retains its previous value while executing commands as the
5358 result of a trap, as the documentation states.
5359
5360 2. Changes to Readline
5361
5362 a. Fixed a bug with prompt redisplay in a multi-byte locale to avoid redrawing
5363 the prompt and input line multiple times.
5364
5365 b. Fixed history expansion to not be confused by here-string redirection.
5366
5367 c. Readline no longer treats read errors by converting them to newlines, as
5368 it does with EOF. This caused partial lines to be returned from readline().
5369
5370 ------------------------------------------------------------------------------
5371 This document details the changes between this version, bash-3.2-alpha,
5372 and the previous version, bash-3.1-release.
5373
5374 1. Changes to Bash
5375
5376 a. Fixed a source bug that caused the minimal configuration to not compile.
5377
5378 b. Fixed memory leaks in error handling for the `read' builtin.
5379
5380 c. Changed the [[ and (( compound commands to set PIPESTATUS with their exit
5381 status.
5382
5383 d. Fixed some parsing problems with compound array assignments.
5384
5385 e. Added additional configuration changes for: NetBSD (incomplete multibyte
5386 character support)
5387
5388 f. Fixed two bugs with local array variable creation when shadowing a variable
5389 of the same name from a previous context.
5390
5391 g. Fixed the `read' builtin to restore the correct set of completion functions
5392 if a timeout occurs.
5393
5394 h. Added code to defer the initialization of HISTSIZE (and its stifling of the
5395 history list) until the history file is loaded, allowing a startup file to
5396 override the default value.
5397
5398 i. Tightened up the arithmetic expression parsing to produce better error
5399 messages when presented with invalid operators.
5400
5401 j. Fixed the cross-compilation support to build the signal list at shell
5402 invocation rather than compile time if cross-compiling.
5403
5404 k. Fixed multibyte support for non-gcc compilers (or compilers that do not
5405 allow automatic array variable sizing based on a non-constant value).
5406
5407 l. Several fixes to the code that manages the list of terminated jobs and
5408 their exit statuses, and the list of active and recently-terminated jobs
5409 to avoid pid aliasing/wraparound and allocation errors.
5410
5411 m. Fixed a problem that allowed scripts to die due to SIGINT while waiting
5412 for children, even when started in the background or otherwise ignoring
5413 SIGINT.
5414
5415 n. Fixed a bug that caused shells invoked as -/bin/bash from not being
5416 recognized as login shells.
5417
5418 o. Fixed a problem that caused shells in the background to give the terminal
5419 to a process group other than the foreground shell process group.
5420
5421 p. Fixed a problem with extracting the `varname' in ${#varname}.
5422
5423 q. Fixed the code that handles SIGQUIT to not exit immediately -- thereby
5424 calling functions that may not be called in a signal handler context --
5425 but set a flag and exit afterward (like SIGINT).
5426
5427 r. Changed the brace expansion code to skip over braces that don't begin a
5428 valid matched brace expansion construct.
5429
5430 s. Fixed `typeset' and `declare' to not require that their shell function
5431 operands to be valid shell identifiers.
5432
5433 t. Changed `test' to use access(2) with a temporary uid/euid swap when testing
5434 file attributes and running setuid, and access(2) in most other cases.
5435
5436 u. Changed completion code to not attempt command name completion on a line
5437 consisting solely of whitespace when no_empty_command_completion is set.
5438
5439 v. The `hash' builtin now prints nothing in posix mode when the hash table is
5440 empty, and prints a message to that effect to stdout instead of stderr
5441 when not in posix mode.
5442
5443 w. Fixed a bug in the extended pattern matching code that caused it to fail to
5444 match periods with certain patterns.
5445
5446 x. Fixed a bug that caused the shell to dump core when performing filename
5447 generation in directories with thousands of files.
5448
5449 y. Returned to the original Bourne shell rules for parsing ``: no recursive
5450 parsing of embedded quoted strings or ${...} constructs.
5451
5452 z. The inheritance of the DEBUG, RETURN, and ERR traps is now dependent only
5453 on the settings of the `functrace' and `errtrace' shell options, rather
5454 than whether or not the shell is in debugging mode.
5455
5456 aa. Fixed a problem with $HOME being converted to ~ in the expansion of
5457 members of the DIRSTACK array.
5458
5459 bb. Fixed a problem with quoted arguments to arithmetic expansions in certain
5460 constructs.
5461
5462 cc. The command word completion code now no longer returns matching directories
5463 while searching $PATH.
5464
5465 dd. Fixed a bug with zero-padding and precision handling in snprintf()
5466 replacement.
5467
5468 ee. Fixed a bug that caused the command substitution code not to take embedded
5469 shell comments into account.
5470
5471 ff. Fixed a bug that caused $((...);(...)) to be misinterpreted as an
5472 arithmetic substitution.
5473
5474 gg. Fixed a bug in the prompt expansion code that inappropriately added a
5475 \001 before a \002 under certain circumstances.
5476
5477 hh. Fixed a bug that caused `unset LANG' to not properly reset the locale
5478 (previous versions would set the locale back to what it was when bash
5479 was started rather than the system's "native" locale).
5480
5481 ii. Fixed a bug that could cause file descriptors > 10 to not be closed even
5482 when closed explicitly by a script.
5483
5484 jj. Fixed a bug that caused single quotes to be stripped from ANSI-C quoting
5485 inside double-quoted command substitutions.
5486
5487 kk. Fixed a bug that could cause core dumps when `return' was executed as the
5488 last element of a pipeline inside a shell function.
5489
5490 ll. Fixed a bug that caused DEBUG trap strings to overwrite commands stored in
5491 the jobs list.
5492
5493 2. Changes to Readline
5494
5495 a. Fixed a problem that caused segmentation faults when using readline in
5496 callback mode and typing consecutive DEL characters on an empty line.
5497
5498 b. Fixed several redisplay problems with multibyte characters, all having to
5499 do with the different code paths and variable meanings between single-byte
5500 and multibyte character redisplay.
5501
5502 c. Fixed a problem with key sequence translation when presented with the
5503 sequence \M-\C-x.
5504
5505 d. Fixed a problem that prevented the `a' command in vi mode from being
5506 undone and redone properly.
5507
5508 e. Fixed a problem that prevented empty inserts in vi mode from being undone
5509 properly.
5510
5511 f. Fixed a problem that caused readline to initialize with an incorrect idea
5512 of whether or not the terminal can autowrap.
5513
5514 g. Fixed output of key bindings (like bash `bind -p') to honor the setting of
5515 convert-meta and use \e where appropriate.
5516
5517 h. Changed the default filename completion function to call the filename
5518 dequoting function if the directory completion hook isn't set. This means
5519 that any directory completion hooks need to dequote the directory name,
5520 since application-specific hooks need to know how the word was quoted,
5521 even if no other changes are made.
5522
5523 i. Fixed a bug with creating the prompt for a non-interactive search string
5524 when there are non-printing characters in the primary prompt.
5525
5526 j. Fixed a bug that caused prompts with invisible characters to be redrawn
5527 multiple times in a multibyte locale.
5528
5529 k. Fixed a bug that could cause the key sequence scanning code to return the
5530 wrong function.
5531
5532 l. Fixed a problem with the callback interface that caused it to fail when
5533 using multi-character keyboard macros.
5534
5535 m. Fixed a bug that could cause a core dump when an edited history entry was
5536 re-executed under certain conditions.
5537
5538 n. Fixed a bug that caused readline to reference freed memory when attmpting
5539 to display a portion of the prompt.
5540
5541 3. New Features in Bash
5542
5543 a. Changed the parameter pattern replacement functions to not anchor the
5544 pattern at the beginning of the string if doing global replacement - that
5545 combination doesn't make any sense.
5546
5547 b. When running in `word expansion only' mode (--wordexp option), inhibit
5548 process substitution.
5549
5550 c. Loadable builtins now work on MacOS X 10.[34].
5551
5552 d. Shells running in posix mode no longer set $HOME, as POSIX requires.
5553
5554 e. The code that checks for binary files being executed as shell scripts now
5555 checks only for NUL rather than any non-printing character.
5556
5557 f. Quoting the string argument to the [[ command's =~ operator now forces
5558 string matching, as with the other pattern-matching operators.
5559
5560 4. New Features in Readline
5561
5562 a. Calling applications can now set the keyboard timeout to 0, allowing
5563 poll-like behavior.
5564
5565 b. The value of SYS_INPUTRC (configurable at compilation time) is now used as
5566 the default last-ditch startup file.
5567
5568 c. The history file reading functions now allow windows-like \r\n line
5569 terminators.
5570
5571 ------------------------------------------------------------------------------
5572 This document details the changes between this version, bash-3.1-release,
5573 and the previous version, bash-3.1-rc2.
5574
5575 1. Changes to Readline
5576
5577 a. Several changes to the multibyte redisplay code to fix problems with
5578 prompts containing invisible characters.
5579
5580 ------------------------------------------------------------------------------
5581 This document details the changes between this version, bash-3.1-rc2,
5582 and the previous version, bash-3.1-rc1.
5583
5584 1. Changes to Bash
5585
5586 a. Fixed a bug that caused a DEBUG trap to overwrite a command string that's
5587 eventually attached to a background job.
5588
5589 b. Changed some code so that filenames with leading tildes with spaces in the
5590 name aren't tilde-expanded by the bash completion code.
5591
5592 c. Fixed a bug that caused the pushd builtin to fail to change to
5593 directories with leading `-'.
5594
5595 d. Fixed a small memory leak in the programmable completion code.
5596
5597 2. Changes to Readline
5598
5599 a. Fixed a redisplay bug caused by moving the cursor vertically to a line
5600 with invisible characters in the prompt in a multibyte locale.
5601
5602 b. Fixed a bug that could cause the terminal special chars to be bound in the
5603 wrong keymap in vi mode.
5604
5605 3. New Features in Bash
5606
5607 a. If compiled for strict POSIX conformance, LINES and COLUMNS may now
5608 override the true terminal size.
5609
5610 4. New Features in Readline
5611
5612 a. A new external application-controllable variable that allows the LINES
5613 and COLUMNS environment variables to set the window size regardless of
5614 what the kernel returns.
5615
5616 ------------------------------------------------------------------------------
5617 This document details the changes between this version, bash-3.1-rc1,
5618 and the previous version, bash-3.1-beta1.
5619
5620 1. Changes to Bash
5621
5622 a. Fixed a bug that could cause core dumps due to accessing the current
5623 pipeline while in the middle of modifying it.
5624
5625 b. Fixed a bug that caused pathnames with backslashes still quoting characters
5626 to be passed to opendir().
5627
5628 c. Command word completion now obeys the setting of completion-ignore-case.
5629
5630 d. Fixed a problem with redirection that caused file descriptors greater than
5631 2 to be inappropriately marked as close-on-exec.
5632
5633 e. In Posix mode, after `wait' is called to wait for a particular process
5634 explicitly, that process is removed from the list of processes known to
5635 the shell, and subsequent attempts to wait for it return errors.
5636
5637 f. Fixed a bug that caused extended pattern matching to incorrectly scan
5638 backslash-escaped pattern characters.
5639
5640 g. Fixed a synchronization problem that could cause core dumps when handling
5641 a SIGWINCH.
5642
5643 h. Fixed a bug that caused an unmatched backquote to be accepted without an
5644 error when processing here documents.
5645
5646 i. Fixed a small memory leak in the `cd' builtin.
5647
5648 j. Fix for MacOS X so it gets the values for the HOSTTYPE, MACHTYPE, and
5649 OSTYPE variables at build time, to support universal binaries.
5650
5651 k. Fixed a bug that could cause an exit trap to return the exit status of
5652 the trap command rather than the status as it was before the trap was
5653 run as the shell's exit status.
5654
5655 2. New Features in Bash
5656
5657 3. Changes to Readline
5658
5659 a. Fixed a bug that caused reversing the incremental search direction to
5660 not work correctly.
5661
5662 b. Fixed the vi-mode `U' command to only undo up to the first time insert mode
5663 was entered, as Posix specifies.
5664
5665 c. Fixed a bug in the vi-mode `r' command that left the cursor in the wrong
5666 place.
5667
5668 4. New Features in Readline
5669
5670 a. New application-callable auxiliary function, rl_variable_value, returns
5671 a string corresponding to a readline variable's value.
5672
5673 b. When parsing inputrc files and variable binding commands, the parser
5674 strips trailing whitespace from values assigned to boolean variables
5675 before checking them.
5676
5677
5678 ------------------------------------------------------------------------------
5679 This document details the changes between this version, bash-3.1-beta1,
5680 and the previous version, bash-3.1-alpha1.
5681
5682 1. Changes to Bash
5683
5684 a. Added some system-specific signal names.
5685
5686 b. Fixed a typo in the ulimit builtin to make `x' the right option to
5687 manipulate the limit on file locks.
5688
5689 c. Fixed a problem with using += to append to index 0 of an array variable
5690 when not using subscript syntax.
5691
5692 d. A few changes to configure.in to remove calls to obsolete or outdated
5693 macros.
5694
5695 e. Make sure changes to variables bash handles specially (e.g., LC_ALL) are
5696 made when the variable is set in the temporary environment to a command.
5697
5698 f. Make sure changes to variables bash handles specially (e.g., LC_ALL) are
5699 made when the variable is modified using `printf -v'.
5700
5701 g. The export environment is now remade on cygwin when HOME is changed, so
5702 DLLs bash is linked against pick up the new value. This fixes problems
5703 with tilde expansion when linking against and already-installed readline.
5704
5705 h. Small fix to the logic for performing tilde expansion in posix mode, so
5706 expansion on the right-hand side of an assignment statement takes place.
5707
5708 i. Fixed a bug that prevented redirections associated with a shell function
5709 from being executed when in a subshell.
5710
5711 j. Fixed `source' and `.' builtins to not require an executable file when
5712 searching $PATH for a file to source.
5713
5714 k. Fixed a bug that caused incorrect word splitting in a function when IFS
5715 was declared local, then unset.
5716
5717 l. Fixed a problem with the `kill' builtin that prevented sending signals
5718 to a process group under certain circumstances when providing a pid < 0.
5719
5720 m. When in POSIX mode, `pwd' now checks that the value it prints is the same
5721 directory as `.', even when displaying $PWD.
5722
5723 n. Fixed a problem with the `read' builtin when reading a script from standard
5724 input and reading data from the same file.
5725
5726 o. Fixed a problem with the `type' and `command' builtins that caused absolute
5727 pathnames to be displayed incorrectly.
5728
5729 p. Some changes to the `bg' builtin for POSIX conformance.
5730
5731 q. The `fc' builtin now removes the `fc' command that caused it to invoke an
5732 editor on specified history entries from the history entirely, rather than
5733 simply ignoring it.
5734
5735 r. When in POSIX mode, the `v' command in vi editing mode simply invokes vi
5736 on the current command, rather than checking $FCEDIT and $EDITOR.
5737
5738 s. Fixed a small memory leak in the pathname canonicalization code.
5739
5740 t. Fixed a bug that caused the expanded value of a $'...' string to be
5741 incorrectly re-quoted if it occurred within a double-quoted ${...}
5742 parameter expansion.
5743
5744 u. Restored default emacs-mode key binding of M-TAB to dynamic-complete-history.
5745
5746 v. Fixed a bug that caused core dumps when interrupting loops running builtins
5747 on some systems.
5748
5749 w. Make sure that some of the functions bash provides replacements for are
5750 not cpp defines.
5751
5752 x. The code that scans embedded commands for the parser (`...` and $(...)) is
5753 now more aware of embedded comments and their effect on quoted strings.
5754
5755 y. Changed the `-n' option to the `history' builtin to not reset the number of
5756 history lines read in the current session after reading the new lines from
5757 the history file if the history is being appended when it is written to
5758 the file, since the appending takes care of the problem that the adjustment
5759 was intended to solve.
5760
5761 z. Improved the error message displayed when a shell script fails to execute
5762 because the environment and size of command line arguments are too large.
5763
5764 aa. A small fix to make sure that $HISTCMD is evaluated whenever the shell is
5765 saving commands to the history list, not just when HISTSIZE is defined.
5766
5767 2. Changes to Readline
5768
5769 a. The `change-case' command now correctly changes the case of multibyte
5770 characters.
5771
5772 b. Changes to the shared library construction scripts to deal with Windows
5773 DLL naming conventions for Cygwin.
5774
5775 c. Fixed the redisplay code to avoid core dumps resulting from a poorly-timed
5776 SIGWINCH.
5777
5778 d. Fixed the non-incremental search code in vi mode to dispose of any current
5779 undo list when copying a line from the history into the current editing
5780 buffer.
5781
5782 e. The variable assignment code now ignores whitespace at the end of lines
5783 when assigning to boolean variables.
5784
5785 f. The `C-w' binding in incremental search now understands multibyte
5786 characters.
5787
5788 3. New Features in Bash
5789
5790 a. A new configuration option, `--enable-strict-posix-default', which will
5791 build bash to be POSIX conforming by default.
5792
5793 4. New Features in Readline
5794
5795 a. If the rl_completion_query_items is set to a value < 0, readline never
5796 asks the user whether or not to view the possible completions.
5797
5798 ------------------------------------------------------------------------------
5799 This document details the changes between this version, bash-3.1-alpha1,
5800 and the previous version, bash-3.0-release.
5801
5802 1. Changes to Bash
5803
5804 a. Fixed a bug that caused bash to crash if referencing an unset local array.
5805
5806 b. Fixed a problem that caused tilde expansion to not be performed before
5807 attempting globbing word completion.
5808
5809 c. Fixed an incompatibility so that a first argument to trap that's a valid
5810 signal number will be trated as a signal rather than a command to execute.
5811
5812 d. Fixed ${#word} expansion to correctly compute the length of a string
5813 containing multibyte characters.
5814
5815 e. Fixed a bug that caused bash to not pass the correct flags for signal
5816 disposition to child processes.
5817
5818 f. Fixed a bug that caused `fc -l' to list one too many history entries.
5819
5820 g. Some fixes to `fc' for POSIX conformance.
5821
5822 h. Some fixes to job status display for POSIX conformance.
5823
5824 i. Fixed a bug that caused `command -v' to display output if a command was not
5825 found -- it should be silent.
5826
5827 j. In POSIX mode, `type' and `command -[vV]' do not report non-executable
5828 files, even if the shell will attempt to execute them.
5829
5830 k. Fixed a bug that caused the `==' operator to the [[ command to not attempt
5831 extended pattern matching.
5832
5833 l. Fixed the brace expansion code to handle characters whose value exceeds 128.
5834
5835 m. Fixed `printf' to handle strings with a leading `\0' whose length is
5836 non-zero.
5837
5838 n. Fixed a couple of problems with brace expansion where `${' was handled
5839 incorrectly.
5840
5841 o. Fixed off-by-one error when calculating the upper bound of `offset' when
5842 processing the ${array[@]:offset:length} expansion.
5843
5844 p. System-specific configuration changes for: FreeBSD 5.x, Interix, MacOS X
5845 10.4, Linux 2.4+ kernels, Linux 3.x kernels, Dragonfly BSD, QNX 6.x,
5846 Cygwin
5847
5848 q. Fixed a bug that caused the shell to ignore the status of the rightmost
5849 command in a pipeline when the `pipefail' option was enabled.
5850
5851 r. Fixed a completion bug that caused core dumps when expanding a directory
5852 name.
5853
5854 s. Fixed a bug that prevented `hash -d' from removing commands from the hash
5855 table.
5856
5857 t. Fixed word splitting to avoid really bad quadratic performance when
5858 expanding long lists.
5859
5860 u. Fixed a bug that caused negative offsets in substring expansion to use the
5861 wrong values.
5862
5863 v. Fixed a bug in printf that caused it to not return failure on write errors.
5864
5865 w. Fixed a bug that caused commands in subshells to not be properly timed.
5866
5867 x. The shell parser no longer attempts to parse a compound assignment specially
5868 unless in a position where an assignment statement is acceptable or parsing
5869 arguments to a builtin that accepts assignment statements.
5870
5871 y. Fixed a problem that caused a `case' statement to be added to the history
5872 incorrectly as a single command if the `case word' was on one line and the
5873 `in' on another.
5874
5875 z. Fixed a problem that caused internal shell quoting characters to be
5876 incorrectly quoted with backslashes under some circumstances.
5877
5878 aa. The shell now performs correct word splitting when IFS contains multibyte
5879 characters.
5880
5881 bb. The mail checking code now resets the cached file information if the size
5882 drops to 0, even if the times don't change.
5883
5884 cc. A completed command name that is found in $PATH as well as the name of a
5885 directory in the current directory no longer has a slash appended in certain
5886 circumstances: a single instance found in $PATH when `.' is not in $PATH,
5887 and multiple instances found in $PATH, even when `.' is in $PATH.
5888
5889 dd. Incorporated tilde expansion into the word expansion code rather than as a
5890 separately-called function, fixing some cases where it was performed
5891 inappropriately (e.g., after the second `=' in an assignment statement or
5892 in a double-quoted parameter expansion).
5893
5894 ee. Fixed several bugs encountered when parsing compound assignment statements,
5895 so that compound assignments appearing as arguments to builtins are no
5896 longer double-expanded.
5897
5898 ff. Fixed a bug in the command execution code that caused asynchronous commands
5899 containing command substitutions to not put the terminal in the wrong
5900 process group.
5901
5902 gg. Bash now handles the case where the WCONTINUED flag causes waitpid() to
5903 return -1/EINVAL at runtime as well as configuration time.
5904
5905 hh. Fixed parser to generate an error when the pipeline `argument' to `!' or
5906 `time' is NULL.
5907
5908 ii. The shell now takes a little more care when manipulating file descriptors
5909 greater than 9 with the `exec' builtin.
5910
5911 jj. Fixed a bug that caused variable assignments preceding the `command' builtin
5912 preceding a special builtin to be preserved after the command completed in
5913 POSIX mode.
5914
5915 kk. Fixed a bug that allowed variables beginning with a digit to be created.
5916
5917 ll. Fixed a bug that caused a \<newline> to be removed when parsing a $'...'
5918 construct.
5919
5920 mm. A shell whose name begins with `-' will now be a restricted shell if the
5921 remainder of the name indicates it should be restricted.
5922
5923 nn. Fixed a bug that could cause a core dump if FUNCNAME were changed or unset
5924 during a function's execution.
5925
5926 oo. Fixed a bug that caused executing a `return' in a function to not execute
5927 a RETURN trap. The RETURN trap is inherited by shell functions only if
5928 function tracing is globally enabled or has been enabled for that function.
5929
5930 pp. Fixed cases where var[@] was not handled exactly like var, when var is a
5931 scalar variable.
5932
5933 qq. Fixed a bug that caused the first character after a SIGINT to be discarded
5934 under certain circumstances.
5935
5936 rr. Fixed exit status code so that a suspended job returns 128+signal as its
5937 exit status (preventing commands after it in `&&' lists from being
5938 executed).
5939
5940 ss. Fixed a bug that caused the shell parser state to be changed by executing
5941 a shell function as a result of word completion.
5942
5943 tt. Fixed a long-standing bug that caused '\177' characters in variable
5944 values to be discarded when expanded in double-quoted strings.
5945
5946 uu. Fixed a bug that caused $RANDOM to be re-seeded multiple times in a
5947 subshell environment.
5948
5949 vv. Extensive changes to the job management code to avoid the pid-reuse and
5950 pid-aliasing problems caused by retaining the exit status of too many jobs,
5951 but still retain as many background job statuses as POSIX requires.
5952
5953 ww. Fixed a parser bug in processing \<newline> that caused things like
5954
5955 ((echo 5) \
5956 (echo 6))
5957
5958 to not work correctly.
5959
5960 xx. `pwd -P' now sets $PWD to a directory name containing no symbolic links
5961 when in posix mode, as POSIX requires.
5962
5963 yy. In posix mode, bash no longer sets $PWD to a name containing no symbolic
5964 links if a directory is chosen from $CDPATH.
5965
5966 zz. The word splitting code now treats an IFS character that is not space,
5967 tab, or newline and any adjacent IFS white space as a single delimiter, as
5968 SUSv3/XPG6 require.
5969
5970 aaa. The `read' builtin now checks whether or not the number of fields read is
5971 exactly the same as the number of variables instead of just assigning the
5972 rest of the line (minus any trailing IFS white space) to the last
5973 variable. This is what POSIX/SUS/XPG all require.
5974
5975 bbb. Fixed a bug that caused `read' to always check whether or not fd 0 was a
5976 pipe, even when reading from another file descriptor.
5977
5978 ccc. Fixed a bug that caused short-circuiting of execution even if the return
5979 value was being inverted.
5980
5981 ddd. Fixed a bug that caused a core dump while decoding \W escapes in PS1 if
5982 PWD was unset.
5983
5984 eee. Fixed a bug in `read' that counted internal quoting characters for the
5985 purposes of `read -n'.
5986
5987 fff. Fixed a bug so that a function definition in a pipeline causes a child
5988 process to be forked at the right time.
5989
5990 ggg. Bash will not attempt to link against a readline library that doesn't
5991 have rl_gnu_readline_p == 1.
5992
5993 hhh. Fixed a bug that caused `read' to consume one too many characters when
5994 reading a fixed number of characters and the Nth character is a backslash.
5995
5996 iii. Fixed a bug that caused `unset' on variables in the temporary environment
5997 to leave them set when `unset' completed.
5998
5999 jjj. Fixed a bug that caused bash to close fd 2 if an `exec' failed and the
6000 shell didn't exit.
6001
6002 kkk. The completion code is more careful to not turn `/' or `///' into `//',
6003 for those systems on which `//' has special meaning.
6004
6005 lll. Fixed a bug that caused command substitution in asynchronous commands to
6006 close the wrong file descriptors.
6007
6008 mmm. The shell no longer prints status messages about terminated background
6009 processes unless job control is active.
6010
6011 nnn. Fixed a bug that prevented multiple consecutive invocations of `history -s'
6012 from adding all the commands to the history list.
6013
6014 ooo. Added a couple of changes to make arithmetic expansion more consistent in
6015 all its contexts (still not perfect).
6016
6017 ppp. Fixed a bug that caused the parser to occasionally not find the right
6018 terminating "`" in an old-style command substitution.
6019
6020 qqq. Fixed a bug that caused core dumps when the shell was reading its non-
6021 interactive input from fd 0 and fd 0 was duplicated and restored using a
6022 combination of `exec' (to save) and redirection (to restore).
6023
6024 rrr. Fixed a problem that caused loops in sourced scripts to not be cleaned
6025 up properly when a `return' is executed.
6026
6027 sss. Change internal command substitution completion function to append a slash
6028 to directory names in the command.
6029
6030 2. Changes to Readline
6031
6032 a. Fixed a bug that caused multiliine prompts to be wrapped and displayed
6033 incorrectly.
6034
6035 b. Fixed a bug that caused ^P/^N in emacs mode to fail to display the current
6036 line correctly.
6037
6038 c. Fixed a problem in computing the number of invisible characters on the first
6039 line of a prompt whose length exceeds the screen width.
6040
6041 d. Fixed vi-mode searching so that failure preserves the current line rather
6042 than the last line in the history list.
6043
6044 e. Fixed the vi-mode `~' command (change-case) to have the correct behavior at
6045 end-of-line when manipulating multibyte characters.
6046
6047 f. Fixed the vi-mode `r' command (change-char) to have the correct behavior at
6048 end-of-line when manipulating multibyte characters.
6049
6050 g. Fixed multiple bugs in the redisplay of multibyte characters: displaying
6051 prompts longer than the screen width containing multibyte characters,
6052
6053 h. Fix the calculation of the number of physical characters in the prompt
6054 string when it contains multibyte characters.
6055
6056 i. A non-zero value for the `rl_complete_suppress_append' variable now causes
6057 no `/' to be appended to a directory name.
6058
6059 j. Fixed forward-word and backward-word to work when words contained
6060 multibyte characters.
6061
6062 k. Fixed a bug in finding the delimiter of a `?' substring when performing
6063 history expansion in a locale that supports multibyte characters.
6064
6065 l. Fixed a memory leak caused by not freeing the timestamp in a history entry.
6066
6067 m. Fixed a bug that caused "\M-x" style key bindings to not obey the setting
6068 of the `convert-meta' variable.
6069
6070 n. Fixed saving and restoring primary prompt when prompting for incremental
6071 and non-incremental searches; search prompts now display multibyte
6072 characters correctly.
6073
6074 o. Fixed a bug that caused keys originally bound to self-insert but shadowed
6075 by a multi-character key sequence to not be inserted.
6076
6077 p. Fixed code so rl_prep_term_function and rl_deprep_term_function aren't
6078 dereferenced if NULL (matching the documentation).
6079
6080 q. Extensive changes to readline to add enough state so that commands
6081 requiring additional characters (searches, multi-key sequences, numeric
6082 arguments, commands requiring an additional specifier character like
6083 vi-mode change-char, etc.) work without synchronously waiting for
6084 additional input.
6085
6086 r. Lots of changes so readline builds and runs on MinGW.
6087
6088 s. Readline no longer tries to modify the terminal settings when running in
6089 callback mode.
6090
6091 t. The Readline display code no longer sets the location of the last invisible
6092 character in the prompt if the \[\] sequence is empty.
6093
6094 3. New Features in Bash
6095
6096 a. Bash now understands LC_TIME as a special variable so that time display
6097 tracks the current locale.
6098
6099 b. BASH_ARGC, BASH_ARGV, BASH_SOURCE, and BASH_LINENO are no longer created
6100 as `invisible' variables and may not be unset.
6101
6102 c. In POSIX mode, if `xpg_echo' option is enabled, the `echo' builtin doesn't
6103 try to interpret any options at all, as POSIX requires.
6104
6105 d. The `bg' builtin now accepts multiple arguments, as POSIX seems to specify.
6106
6107 e. Fixed vi-mode word completion and glob expansion to perform tilde
6108 expansion.
6109
6110 f. The `**' mathematic exponentiation operator is now right-associative.
6111
6112 g. The `ulimit' builtin has new options: -i (max number of pending signals),
6113 -q (max size of POSIX message queues), and -x (max number of file locks).
6114
6115 h. A bare `%' once again expands to the current job when used as a job
6116 specifier.
6117
6118 i. The `+=' assignment operator (append to the value of a string or array) is
6119 now supported for assignment statements and arguments to builtin commands
6120 that accept assignment statements.
6121
6122 j. BASH_COMMAND now preserves its value when a DEBUG trap is executed.
6123
6124 k. The `gnu_errfmt' option is enabled automatically if the shell is running
6125 in an emacs terminal window.
6126
6127 l. New configuration option: --single-help-strings. Causes long help text
6128 to be written as a single string; intended to ease translation.
6129
6130 m. The COMP_WORDBREAKS variable now causes the list of word break characters
6131 to be emptied when the variable is unset.
6132
6133 n. An unquoted expansion of $* when $IFS is empty now causes the positional
6134 parameters to be concatenated if the expansion doesn't undergo word
6135 splitting.
6136
6137 o. Bash now inherits $_ from the environment if it appears there at startup.
6138
6139 p. New shell option: nocasematch. If non-zero, shell pattern matching ignores
6140 case when used by `case' and `[[' commands.
6141
6142 q. The `printf' builtin takes a new option: -v var. That causes the output
6143 to be placed into var instead of on stdout.
6144
6145 r. By default, the shell no longer reports processes dying from SIGPIPE.
6146
6147 s. Bash now sets the extern variable `environ' to the export environment it
6148 creates, so C library functions that call getenv() (and can't use the
6149 shell-provided replacement) get current values of environment variables.
6150
6151 4. New Features in Readline
6152
6153 a. The key sequence sent by the keypad `delete' key is now automatically
6154 bound to delete-char.
6155
6156 b. A negative argument to menu-complete now cycles backward through the
6157 completion list.
6158
6159 c. A new bindable readline variable: bind-tty-special-chars. If non-zero,
6160 readline will bind the terminal special characters to their readline
6161 equivalents when it's called (on by default).
6162
6163 d. New bindable command: vi-rubout. Saves deleted text for possible
6164 reinsertion, as with any vi-mode `text modification' command; `X' is bound
6165 to this in vi command mode.
6166
6167 ------------------------------------------------------------------------------
6168 This document details the changes between this version, bash-3.0-release,
6169 and the previous version, bash-3.0-rc1.
6170
6171 1. Changes to Bash
6172
6173 a. Fixed a boundary overrun that could cause segmentation faults when the
6174 completion code hands an incomplete construct to the word expansion
6175 functions.
6176
6177 b. Changed posix mode behavior so that an error in a variable assignment
6178 preceding a special builtin causes a non-interactive shell to exit.
6179
6180 c. Change the directory expansion portion of the completion code to not
6181 expand embedded command substitutions if the directory name appears in
6182 the file system.
6183
6184 d. Fixed a problem that caused `bash -r' to turn on restrictions before
6185 reading the startup files.
6186
6187 e. Fixed a problem with the default operation of the `umask' builtin.
6188
6189 2. Changes to Readline
6190
6191 a. Fixed a problem with readline saving the contents of the current line
6192 before beginning a non-interactive search.
6193
6194 b. Fixed a problem with EOF detection when using rl_event_hook.
6195
6196 c. Fixed a problem with the vi mode `p' and `P' commands ignoring numeric
6197 arguments.
6198
6199 ------------------------------------------------------------------------------
6200 This document details the changes between this version, bash-3.0-rc1,
6201 and the previous version, bash-3.0-beta1.
6202
6203 1. Changes to Bash
6204
6205 a. Fixed a bug that caused incorrect behavior when referecing element 0 of
6206 an array using $array, element 0 was unset, and `set -u' was enabled.
6207
6208 b. System-specific changes for: SCO Unix 3.2, Tandem.
6209
6210 c. Fixed a bug that caused inappropriate word splitting when a variable was
6211 expanded within a double-quoted string that also included $@.
6212
6213 d. Fixed a bug that caused `pwd' to not display anything in physical mode
6214 when the file system had changed underneath the shell.
6215
6216 e. Fixed a bug in the pre- and post- increment and decrement parsing in the
6217 expression evaluator that caused errors when the operands and corresponding
6218 operators were separated by whitespace.
6219
6220 f. Fixed a bug that caused `history -p' to add an entry to the history list,
6221 counter to the documentation. (Keeps the history expansions invoked by
6222 emacs-mode command line editing from doing that as well.)
6223
6224 g. Fixed a bug that could cause a core dump if `cd' is asked to print out a
6225 pathname longer than PATH_MAX characters.
6226
6227 h. Fixed a bug that caused jobs to be put into the wrong process group under
6228 some circumstances after enabling job control with `set -m'.
6229
6230 i. `unalias' now returns failure if no alias name arguments are supplied.
6231
6232 j. Documented the characters not allowed to appear in an alias name.
6233
6234 k. $* is no longer expanded as if in double quotes when it appears in the
6235 body of a here document, as the SUS seems to require.
6236
6237 l. The `bashbug' script now uses a directory in $TMPDIR for exclusive
6238 access rather than trying to guess how the underlying OS provides for
6239 secure temporary file creation.
6240
6241 m. Fixed a few problems with `cd' and `pwd' when asked to operate on pathnames
6242 longer than PATH_MAX characters.
6243
6244 n. Fixed a memory leak caused when creating multiple local array variables
6245 with identical names.
6246
6247 o. Fixed a problem with calls to getcwd() so that bash now operates better
6248 when the full pathname to the current directory is longer than PATH_MAX
6249 bytes.
6250
6251 p. The `trap' builtin now reports an error if a single non-signal argument
6252 is specified.
6253
6254 q. Fixed a bug that caused `umask' to not work correctly when presented
6255 with a mask of all 0s.
6256
6257 r. When `getopts' reaches the end of options, OPTARG is unset, as POSIX
6258 appears to specify.
6259
6260 s. Interactive mode now depends on whether or not stdin and stderr are
6261 connected to a tty; formerly it was stdin and stdout. POSIX requires
6262 this.
6263
6264 t. Fixed vi-mode completion to work more as POSIX specifies (e.g., doing the
6265 right kind of filename generation).
6266
6267 2. Changes to Readline
6268
6269 a. Fixed a problem that could cause readline to refer to freed memory when
6270 moving between history lines while doing searches.
6271
6272 b. Improvements to the code that expands and displays prompt strings
6273 containing multibyte characters.
6274
6275 c. Fixed a problem with vi-mode not correctly remembering the numeric argument
6276 to the last `c'hange command for later use with `.'.
6277
6278 d. Fixed a bug in vi-mode that caused multi-digit count arguments to work
6279 incorrectly.
6280
6281 e. Fixed a problem in vi-mode that caused the last text modification command
6282 to not be remembered across different command lines.
6283
6284 f. Fixed problems with changing characters and changing case at the end of
6285 the line.
6286
6287 3. New Features in Bash
6288
6289 a. The `jobs', `kill', and `wait' builtins now accept job control notation
6290 even if job control is not enabled.
6291
6292 b. The historical behavior of `trap' that allows a missing `action' argument
6293 to cause each specified signal's handling to be reset to its default is
6294 now only supported when `trap' is given a single non-option argument.
6295
6296 4. New Features in Readline
6297
6298 a. When listing completions, directories have a `/' appended if the
6299 `mark-directories' option has been enabled.
6300
6301 ------------------------------------------------------------------------------
6302 This document details the changes between this version, bash-3.0-beta1,
6303 and the previous version, bash-3.0-alpha.
6304
6305 1. Changes to Bash
6306
6307 a. Fixes to build correctly when arrays are not compiled into the shell.
6308
6309 b. Fixed command substitution to run any exit trap defined in the command
6310 substitution before returning; the exit trap is not inherited from the
6311 calling shell.
6312
6313 c. Fixes to process group synchronization code so that every child process
6314 attempts to set the terminal's process group; fixes some synchronization
6315 problems on Linux kernels that schedule the child to always run before
6316 the parent.
6317
6318 d. Fixed processing of octal and hex constants in printf builtin for POSIX.2
6319 compliance.
6320
6321 e. Fixed a couple of core dumps in the pattern removal code.
6322
6323 f. Fixes to the array subrange extraction code to deal better with sparse
6324 arrays.
6325
6326 g. Parser errors and other errors that result in the shell exiting now cause
6327 the exit trap to be run.
6328
6329 h. Change the command substitution completion functions to not append any
6330 closing quote, because it would be inserted a closing "`" or ")".
6331
6332 i. Fix history initialization so assignments to $histchars made in startup
6333 files are honored.
6334
6335 j. If an exit trap does not contain a call to `exit', the shell now uses
6336 the exit status of the last command executed before the trap as the exit
6337 status of the shell.
6338
6339 k. The parser now prompts with $PS2 if it reads a newline while parsing a
6340 compound array assignment statement.
6341
6342 l. When performing a compound array assignment, the parser doesn't treat
6343 words of the form [index]=value as assignments if they're the result of
6344 expansions.
6345
6346 m. Fixed a bug that caused `return' executed in a trap command to make the
6347 shell think it was still running the trap.
6348
6349 n. Fixed the value of errno set by the pathname canonicalization functions.
6350
6351 o. Changed the grammar so that `time' alone on a line times a null command
6352 rather than being a syntax error.
6353
6354 p. The pattern substitution code no longer performs quote removal on the
6355 pattern before trying to match it, as the pattern removal functions do.
6356
6357 q. Fixed a bug that could cause core dumps when checking whether a quoted
6358 command name was being completed.
6359
6360 r. Fixes to the pattern removal and pattern replacement expansions to deal
6361 with multibyte characters better (and faster).
6362
6363 s. Fix to the substring expansion (${param:off[:len]}) to deal with (possibly
6364 multibyte) characters instead of raw bytes.
6365
6366 t. Fixed a bug that caused some key bindings set in an inputrc to be ignored
6367 at shell startup.
6368
6369 u. Fixed a bug that caused unsetting a local variable within a function to
6370 not work correctly.
6371
6372 v. Fixed a bug that caused invalid variables to be created when using
6373 `read -a'.
6374
6375 w. Fixed a bug that caused "$@" to expand incorrectly when used as the right
6376 hand side of a parameter expansion such as ${word:="$@"} if the first
6377 character of $IFS was not a space.
6378
6379 x. Fixed a slight cosmetic problem when printing commands containing a
6380 `>&word' redirection.
6381
6382 y. Fixed a problem that could cause here documents to not be created correctly
6383 if the system temporary directory did not allow writing.
6384
6385 2. Changes to Readline
6386
6387 a. Change to history expansion functions to treat `^' as equivalent to word
6388 one, as the documentation states.
6389
6390 b. Some changes to the display code to improve display and redisplay of
6391 multibyte characters.
6392
6393 c. Changes to speed up the multibyte character redisplay code.
6394
6395 d. Fixed a bug in the vi-mode `E' command that caused it to skip over the
6396 last character of a word if invoked while point was on the word's
6397 next-to-last character.
6398
6399 e. Fixed a bug that could cause incorrect filename quoting when
6400 case-insensitive completion was enabled and the word being completed
6401 contained backslashes quoting word break characters.
6402
6403 f. Fixed a bug in redisplay triggered when the prompt string contains
6404 invisible characters.
6405
6406 g. Fixed some display (and other) bugs encountered in multibyte locales
6407 when a non-ascii character was the last character on a line.
6408
6409 h. Fixed some display bugs caused by multibyte characters in prompt strings.
6410
6411 i. Fixed a problem with history expansion caused by non-whitespace characters
6412 used as history word delimiters.
6413
6414 3. New Features in Bash
6415
6416 a. printf builtin understands two new escape sequences: \" and \?.
6417
6418 b. `echo -e' understands two new escape sequences: \" and \?.
6419
6420 c. The GNU `gettext' package and libintl have been integrated; the shell's
6421 messages can be translated into different languages.
6422
6423 d. The `\W' prompt expansion now abbreviates $HOME as `~', like `\w'.
6424
6425 e. The error message printed when bash cannot open a shell script supplied
6426 as argument 1 now includes the name of the shell, to better identify
6427 the error as coming from bash.
6428
6429 4. New Features in Readline
6430
6431 a. New application variable, rl_completion_quote_character, set to any
6432 quote character readline finds before it calls the application completion
6433 function.
6434
6435 b. New application variable, rl_completion_suppress_quote, settable by an
6436 application completion function. If set to non-zero, readline does not
6437 attempt to append a closing quote to a completed word.
6438
6439 c. New application variable, rl_completion_found_quote, set to a non-zero
6440 value if readline determines that the word to be completed is quoted.
6441 Set before readline calls any application completion function.
6442
6443 d. New function hook, rl_completion_word_break_hook, called when readline
6444 needs to break a line into words when completion is attempted. Allows
6445 the word break characters to vary based on position in the line.
6446
6447 e. New bindable command: unix-filename-rubout. Does the same thing as
6448 unix-word-rubout, but adds `/' to the set of word delimiters.
6449
6450 ------------------------------------------------------------------------------
6451 This document details the changes between this version, bash-3.0-alpha,
6452 and the previous version, bash-2.05b-release.
6453
6454 1. Changes to Bash
6455
6456 a. Fixes so that the shell will compile without some of the default options
6457 defined.
6458
6459 b. Fixed an error message that did not pass enough arguments to printf.
6460
6461 c. Fixed a bug that caused input redirection to a builtin inside a script
6462 being read from standard input to result in the rest of the already-
6463 read and buffered script to be discarded.
6464
6465 d. Fixed a bug that caused subshell initialization to close the file
6466 descriptor from which the shell was reading a script under certain
6467 circumstances.
6468
6469 e. Fixed a bug that caused the shell to not advance a string pointer over
6470 a null wide character when doing string operations.
6471
6472 f. Fixed the internal logout code so that shells that time out waiting for
6473 input (using $TMOUT) run ~/.bash_logout.
6474
6475 g. Portability and configuration changes for: cygwin, HP/UX, GNU/FreeBSD.
6476
6477 h. The parser no longer adds implicit double quotes to ((...)) arithmetic
6478 commands.
6479
6480 i. The ((...)) arithmetic command evaluation code was fixed to not dump core
6481 when the expanded string is null.
6482
6483 j. The ((...)) arithmetic command evaluation code was fixed to not perform
6484 variable assignments while expanding the expression.
6485
6486 k. Fixed a bug that caused word splitting to be performed incorrectly when
6487 IFS is set, but null.
6488
6489 l. Fixed a bug in brace expansion that caused a quoted `$' preceding an
6490 open brace to inhibit brace expansion.
6491
6492 m. Fixed a bug that caused a leading `-' in the shell's name to cause it to
6493 not be recognized as a restricted shell.
6494
6495 n. Fixed a bug in the arithmetic evaluation code that could cause longjmps
6496 to an invalid location and result in a core dump.
6497
6498 o. Fixed a bug in the calculation of how many history lines are new in a
6499 single shell session when reading new history lines from a file with
6500 `history -n'.
6501
6502 p. Fixed a bug in pathname canonicalization that caused the shell to dump
6503 core when presented with a pathname longer than PATH_MAX.
6504
6505 q. Fixed the parser so that it doesn't try to compare a char variable to
6506 EOF, which fails when chars are unsigned.
6507
6508 r. Fixed a bug in the simple command execution code that caused occasional
6509 core dumps.
6510
6511 s. The shell does a better job of saving any partial parsing state during
6512 operations which cause a command to be executed while a line is being
6513 entered and parsed.
6514
6515 t. The completion code now splits words more like the expansion code when
6516 $IFS is used to split.
6517
6518 u. The locale code does a better job of recomputing the various locale
6519 variable values when LC_ALL is unset.
6520
6521 v. The programmable completion code does a better job of dequoting expanded
6522 word lists before comparing them against the word to be matched.
6523
6524 w. The shell no longer seg faults if the expanded value of $PS4 is null
6525 and `set -x' is enabled.
6526
6527 x. Fixed a bug that caused core dumps when a here string expanded to NULL.
6528
6529 y. The mail checking code now makes sure the mailbox is bigger before
6530 reporting the existence of new mail.
6531
6532 z. The parser does not try to expand $'...' and $"..." when the appear
6533 within double quotes unless the `extquote' option has been enabled with
6534 `shopt'. For backwards compatibility, it is enabled by default.
6535
6536 aa. Fixed a bug that caused `for x; do ...' and `select x; do ... to use
6537 $@ instead of "$@" for the implicit list of arguments.
6538
6539 bb. Fixed a bug that caused a subshell of a restricted shell (e.g., one
6540 spawned to execute a pipeline) to not exit immediately if attempting
6541 to use a command containing a slash.
6542
6543 cc. Fixed a problem with empty replacements for a pattern that doesn't match
6544 when performing ${param/word/} expansion.
6545
6546 dd. Word expansions performed while expanding redirections no longer search
6547 a command's temporary environment to expand variable values.
6548
6549 ee. Improvements to the alias expansion code when expanding subsequent words
6550 because an aliase's value ends with a space.
6551
6552 ff. `cd -' now prints the current working directory after a successful chdir
6553 even when the shell is not interactive, as the standard requires.
6554
6555 gg. The shell does a better job of ensuring a child process dies of SIGINT
6556 before resending SIGINT to itself.
6557
6558 hh. The arithmetic expansion variable assignment code now does the right
6559 thing when assigning to `special' variables like OPTIND.
6560
6561 ii. When history expansion verification is enabled, the bash readline helper
6562 functions that do history expansion on the current line don't print
6563 the results.
6564
6565 jj. Fixed bugs with multiple consecutive alias expansion when one of the
6566 expansions ends with a space.
6567
6568 kk. Fixed a problem in the programmable completion code that could cause core
6569 dumps when trying to initialize a set of possible completions from a
6570 list of variables.
6571
6572 ll. The \[ and \] escape characters are now ignored when decoding the prompt
6573 string if the shell is started with editing disabled.
6574
6575 mm. Fixed a bug that could leave extra characters in a string when doing
6576 quoted null character removal.
6577
6578 nn. Command substitution and other subshell operations no longer reset the
6579 line number (aids the bash debugger).
6580
6581 oo. Better line number management when executing simple commands, conditional
6582 commands, for commands, and select commands.
6583
6584 pp. The globbing code now uses malloc, with its better failure properties,
6585 rather than alloca().
6586
6587 qq. Fixed a bug that caused expansions like #{a[2]:=value} to create the
6588 appropriate array element instead of a variable named `a[2]'.
6589
6590 rr. Fixed a bug in the handling of a `?(...)' pattern immediately following
6591 a `*' when extglob is enabled.
6592
6593 ss. Fixed a bug that caused a `return' invoked in an exit trap when exit is
6594 invoked in a function to misbehave.
6595
6596 tt. Fixed a bug that caused CTLESC and CTLNUL characters to not be escaped
6597 by the internal shell string quoting functions.
6598
6599 uu. Fixed a bug that caused quoted null characters in an expanded word list
6600 to be inappropriately assigned to an array variable when using `read -a'.
6601
6602 vv. Fixed a bug that caused redirections accompanying a null command to persist
6603 in the current shell.
6604
6605 ww. Fixed a bug that caused the prompt to be printed when the shell was
6606 expanding a multiline alias.
6607
6608 xx. Fixed a bug that resulted in core dumps when the completion for a command
6609 changed the compspec.
6610
6611 yy. Fixed a bug that caused evaluation of programmable completions to print
6612 notifications of completed jobs.
6613
6614 zz. Bash now disables line editing when $EMACS == `t' and $TERM == `dumb'
6615 (which is what emacs shell windows do).
6616
6617 aaa. In posix mode, `kill -l' causes signal names to be displayed without
6618 a leading `SIG'.
6619
6620 bbb. Clear error flag on standard output so it doesn't persist across multiple
6621 builtin commands.
6622
6623 ccc. In posix mode, `alias' displays alias values without the leading `alias',
6624 so the output cannot be used as subsequent input.
6625
6626 ddd. In posix mode, the `trap' builtin doesn't check whether or not its
6627 first argument is a signal specification and revert the signal handling
6628 to its original disposition if it is.
6629
6630 eee. Fixed several bugs in the handling of "$*" and "${array[*]}" by the
6631 pattern substitution and removal expansions.
6632
6633 fff. Fixed several problems with the handling of ${array[@]}, ${array[*]},
6634 $@, and $* by the indirect variable expansion code.
6635
6636 ggg. Fixed a bug that did not allow `time' to be aliased.
6637
6638 hhh. Improved the mail checking code so it won't check (and possibly cause an
6639 NFS file system mount) until MAILPATH or MAIL is given a value -- there
6640 is no default if DEFAULT_MAIL_DIRECTORY is not defined at compile time.
6641 (It is computed by configure, but can be #undef'd in config-bot.h.)
6642
6643 iii. If the `chkwinsize' option is enabled, the shell checks for window size
6644 changes if a child process exits due to a signal.
6645
6646 jjj. Removed the attempts to avoid adding a slash at the end of a completed
6647 executable name if there was a directory with the same name in the
6648 current directory.
6649
6650 kkk. Fixed PATH lookup code so it treats the permission bits separately for
6651 owner, group, and other, rather than checking them all.
6652
6653 lll. Fixed the locale code to reset the parser's idea of the character class
6654 <blank>, which controls how it splits tokens, when the locale changes.
6655
6656 mmm. The shell now binds its special readline functions and key bindings only
6657 if the user's inputrc file has not already bound them.
6658
6659 nnn. The shell now reports on processes that dump core due to signals when
6660 invoked as `-c command'.
6661
6662 2. Changes to Readline
6663
6664 a. Fixes to avoid core dumps because of null pointer references in the
6665 multibyte character code.
6666
6667 b. Fix to avoid infinite recursion caused by certain key combinations.
6668
6669 c. Fixed a bug that caused the vi-mode `last command' to be set incorrectly.
6670
6671 d. Readline no longer tries to read ahead more than one line of input, even
6672 when more is available.
6673
6674 e. Fixed the code that adjusts the point to not mishandle null wide
6675 characters.
6676
6677 f. Fixed a bug in the history expansion `g' modifier that caused it to skip
6678 every other match.
6679
6680 g. Fixed a bug that caused the prompt to overwrite previous output when the
6681 output doesn't contain a newline and the locale supports multibyte
6682 characters. This same change fixes the problem of readline redisplay
6683 slowing down dramatically as the line gets longer in multibyte locales.
6684
6685 h. History traversal with arrow keys in vi insertion mode causes the cursor
6686 to be placed at the end of the new line, like in emacs mode.
6687
6688 i. The locale initialization code does a better job of using the right
6689 precedence and defaulting when checking the appropriate environment
6690 variables.
6691
6692 j. Fixed the history word tokenizer to handle <( and >( better when used as
6693 part of bash.
6694
6695 k. The overwrite mode code received several bug fixes to improve undo.
6696
6697 l. Many speedups to the multibyte character redisplay code.
6698
6699 m. The callback character reading interface should not hang waiting to read
6700 keyboard input.
6701
6702 n. Fixed a bug with redoing vi-mode `s' command.
6703
6704 o. The code that initializes the terminal tracks changes made to the terminal
6705 special characters with stty(1) (or equivalent), so that these changes
6706 are reflected in the readline bindings. New application-callable function
6707 to make it work: rl_tty_unset_default_bindings().
6708
6709 p. Fixed a bug that could cause garbage to be inserted in the buffer when
6710 changing character case in vi mode when using a multibyte locale.
6711
6712 q. Fixed a bug in the redisplay code that caused problems on systems
6713 supporting multibyte characters when moving between history lines when the
6714 new line has more glyphs but fewer bytes.
6715
6716 r. Undo and redo now work better after exiting vi insertion mode.
6717
6718 s. Make sure system calls are restarted after a SIGWINCH is received using
6719 SA_RESTART.
6720
6721 t. Improvements to the code that displays possible completions when using
6722 multibyte characters.
6723
6724 u. Fixed a problem when parsing nested if statements in inputrc files.
6725
6726 v. The completer now takes multibyte characters into account when looking for
6727 quoted substrings on which to perform completion.
6728
6729 w. The history search functions now perform better bounds checking on the
6730 history list.
6731
6732 3. New Features in Bash
6733
6734 a. ANSI string expansion now implements the \x{hexdigits} escape.
6735
6736 b. There is a new loadable `strftime' builtin.
6737
6738 c. New variable, COMP_WORDBREAKS, which controls the readline completer's
6739 idea of word break characters.
6740
6741 d. The `type' builtin no longer reports on aliases unless alias expansion
6742 will actually be performed.
6743
6744 e. HISTCONTROL is now a colon-separated list of values, which permits
6745 more extensibility and backwards compatibility.
6746
6747 f. HISTCONTROL may now include the `erasedups' option, which causes all lines
6748 matching a line being added to be removed from the history list.
6749
6750 g. `configure' has a new `--enable-multibyte' argument that permits multibyte
6751 character support to be disabled even on systems that support it.
6752
6753 h. New variables to support the bash debugger: BASH_ARGC, BASH_ARGV,
6754 BASH_SOURCE, BASH_LINENO, BASH_SUBSHELL, BASH_EXECUTION_STRING,
6755 BASH_COMMAND
6756
6757 i. FUNCNAME has been changed to support the debugger: it's now an array
6758 variable.
6759
6760 j. for, case, select, arithmetic commands now keep line number information
6761 for the debugger.
6762
6763 k. There is a new `RETURN' trap executed when a function or sourced script
6764 returns (not inherited child processes; inherited by command substitution
6765 if function tracing is enabled and the debugger is active).
6766
6767 l. New invocation option: --debugger. Enables debugging and turns on new
6768 `extdebug' shell option.
6769
6770 m. New `functrace' and `errtrace' options to `set -o' cause DEBUG and ERR
6771 traps, respectively, to be inherited by shell functions. Equivalent to
6772 `set -T' and `set -E' respectively. The `functrace' option also controls
6773 whether or not the DEBUG trap is inherited by sourced scripts.
6774
6775 n. The DEBUG trap is run before binding the variable and running the action
6776 list in a `for' command, binding the selection variable and running the
6777 query in a `select' command, and before attempting a match in a `case'
6778 command.
6779
6780 o. New `--enable-debugger' option to `configure' to compile in the debugger
6781 support code.
6782
6783 p. `declare -F' now prints out extra line number and source file information
6784 if the `extdebug' option is set.
6785
6786 q. If `extdebug' is enabled, a non-zero return value from a DEBUG trap causes
6787 the next command to be skipped, and a return value of 2 while in a
6788 function or sourced script forces a `return'.
6789
6790 r. New `caller' builtin to provide a call stack for the bash debugger.
6791
6792 s. The DEBUG trap is run just before the first command in a function body is
6793 executed, for the debugger.
6794
6795 t. `for', `select', and `case' command heads are printed when `set -x' is
6796 enabled.
6797
6798 u. There is a new {x..y} brace expansion, which is shorthand for {x.x+1,
6799 x+2,...,y}. x and y can be integers or single characters; the sequence
6800 may ascend or descend; the increment is always 1.
6801
6802 v. New ksh93-like ${!array[@]} expansion, expands to all the keys (indices)
6803 of array.
6804
6805 w. New `force_fignore' shopt option; if enabled, suffixes specified by
6806 FIGNORE cause words to be ignored when performing word completion even
6807 if they're the only possibilities.
6808
6809 x. New `gnu_errfmt' shopt option; if enabled, error messages follow the `gnu
6810 style' (filename:lineno:message) format.
6811
6812 y. New `-o bashdefault' option to complete and compgen; if set, causes the
6813 whole set of bash completions to be performed if the compspec doesn't
6814 result in a match.
6815
6816 z. New `-o plusdirs' option to complete and compgen; if set, causes directory
6817 name completion to be performed and the results added to the rest of the
6818 possible completions.
6819
6820 aa. `kill' is available as a builtin even when the shell is built without
6821 job control.
6822
6823 bb. New HISTTIMEFORMAT variable; value is a format string to pass to
6824 strftime(3). If set and not null, the `history' builtin prints out
6825 timestamp information according to the specified format when displaying
6826 history entries. If set, bash tells the history library to write out
6827 timestamp information when the history file is written.
6828
6829 cc. The [[ ... ]] command has a new binary `=~' operator that performs
6830 extended regular expression (egrep-like) matching.
6831
6832 dd. `configure' has a new `--enable-cond-regexp' option (enabled by default)
6833 to enable the =~ operator and regexp matching in [[ ... ]].
6834
6835 ee. Subexpressions matched by the =~ operator are placed in the new
6836 BASH_REMATCH array variable.
6837
6838 ff. New `failglob' option that causes an expansion error when pathname
6839 expansion fails to produce a match.
6840
6841 gg. New `set -o pipefail' option that causes a pipeline to return a failure
6842 status if any of the processes in the pipeline fail, not just the last
6843 one.
6844
6845 4. New Features in Readline
6846
6847 a. History expansion has a new `a' modifier equivalent to the `g' modifier
6848 for compatibility with the BSD csh.
6849
6850 b. History expansion has a new `G' modifier equivalent to the BSD csh `g'
6851 modifier, which performs a substitution once per word.
6852
6853 c. All non-incremental search operations may now undo the operation of
6854 replacing the current line with the history line.
6855
6856 d. The text inserted by an `a' command in vi mode can be reinserted with
6857 `.'.
6858
6859 e. New bindable variable, `show-all-if-unmodified'. If set, the readline
6860 completer will list possible completions immediately if there is more
6861 than one completion and partial completion cannot be performed.
6862
6863 f. There is a new application-callable `free_history_entry()' function.
6864
6865 g. History list entries now contain timestamp information; the history file
6866 functions know how to read and write timestamp information associated
6867 with each entry.
6868
6869 h. Four new key binding functions have been added:
6870
6871 rl_bind_key_if_unbound()
6872 rl_bind_key_if_unbound_in_map()
6873 rl_bind_keyseq_if_unbound()
6874 rl_bind_keyseq_if_unbound_in_map()
6875
6876 ------------------------------------------------------------------------------
6877 This document details the changes between this version, bash-2.05b-release,
6878 and the previous version, bash-2.05b-beta2.
6879
6880 1. Changes to Bash
6881
6882 a. Fixed an off-by-one error in the function that translates job
6883 specifications.
6884
6885 b. Note that we're running under Emacs and disable line editing if
6886 $EMACS == `t'.
6887
6888 ------------------------------------------------------------------------------
6889 This document details the changes between this version, bash-2.05b-beta2,
6890 and the previous version, bash-2.05b-beta1.
6891
6892 1. Changes to Bash
6893
6894 a. Fixed the /= and %= arithmetic operators to catch division by zero.
6895
6896 b. Added putenv, setenv, unsetenv to getenv replacement for completeness.
6897
6898 c. Fixed a bug that could cause the -O expand_aliases invocation option
6899 to not take effect.
6900
6901 d. Fixed a problem with process substitution that resulted in incorrect
6902 behavior when the number of process substitutions in an individual
6903 command approached 64.
6904
6905 2. Changes to Readline
6906
6907 a. Fixed a problem with backward-char-search when on a system with support
6908 for multibyte characters when running in a locale without any multibyte
6909 characters.
6910
6911 ------------------------------------------------------------------------------
6912 This document details the changes between this version, bash-2.05b-beta1,
6913 and the previous version, bash-2.05b-alpha1.
6914
6915 1. Changes to Bash
6916
6917 a. Fixed a problem when parsing a POSIX.2 character class name while
6918 evaluating a bracket expression containing multibyte characters.
6919
6920 b. Changed the help text for `bind' to make it clear that any command
6921 that may be placed in ~/.inputrc is a valid argument to `bind'.
6922
6923 c. Added `help' builtin entries for `((', `[[', and arithmetic for.
6924
6925 d. malloc updated again:
6926 o slightly better overflow and underflow detection by putting the
6927 chunk size at the beginning and end of the chunk and making
6928 sure they match in free/realloc
6929 o partial page allocated to make things page-aligned no longer
6930 completely wasted
6931 o block coalescing now enabled by default
6932 o splitting and coalescing enabled for 32-byte chunks, the most
6933 common size requested
6934 o fixed a problem that resulted in spurious underflow messages and
6935 aborts
6936 o bin sizes are precomputed and stored in an array rather than
6937 being computed at run time
6938 o malloc will return memory blocks back to the system if the block
6939 being freed is at the top of the heap and of sufficient size to
6940 make it worthwhile
6941 o malloc/free/realloc now inline memset instead of calling the
6942 libc function; uses Duff's device for good performance
6943
6944 e. Check for getservent(); make the service name completion code dependent
6945 on its presence.
6946
6947 f. Changed the readline callback that executes a command bound to a key
6948 sequence to not save the executed command on the history list and to
6949 save and restore the parsing state.
6950
6951 g. Changes to lib/sh/snprintf.c: fixed some bugs in the `g' and `G'
6952 floating point format display; implemented the "'" flag character
6953 that turns on thousands' grouping; fixed behavior on systems where
6954 MB_CUR_MAX does not evaluate to a constant.
6955
6956 h. The `unset' builtin no longer returns a failure status when asked to
6957 unset a previously-unset variable or function.
6958
6959 i. Changes to the build system to make it easier to cross-compile bash
6960 for different systems.
6961
6962 j. Added `,' to the characters that are backslash-escaped during filename
6963 completion, to avoid problems with complete-into-braces and RCS filenames
6964 containing commas.
6965
6966 k. Some changes to the multibyte character support code to avoid many calls
6967 to strlen().
6968
6969 l. Bash now correctly honors setting LANG to some value when LC_ALL does not
6970 already have a value.
6971
6972 m. Fixed a bug that could cause SIGSEGV when processing nested traps with
6973 trap handlers.
6974
6975 n. The `source/.' builtin now restores the positional parameters when it
6976 returns unless they were changed using the `set' builtin during the file's
6977 execution.
6978
6979 o. Fixed a bug that caused a syntax error when a command was terminated by
6980 EOF.
6981
6982 2. New Features in Bash
6983
6984 a. There is now support for placing the long help text into separate files
6985 installed into ${datadir}/bash. Not enabled by default; can be turned
6986 on with `--enable-separate-helpfiles' option to configure.
6987
6988 b. All builtins that take operands accept a `--' pseudo-option, except
6989 `echo'.
6990
6991 c. The `echo' builtin now accepts \0xxx (zero to three octal digits following
6992 the `0') in addition to \xxx (one to three octal digits) for SUSv3/XPG6/
6993 POSIX.1-2001 compliance.
6994
6995 3. Changes to Readline
6996
6997 a. Fixed a small problem in _rl_insert_char with multibyte characters.
6998
6999 b. Fixes from IBM for line wrapping problems when using multibyte characters.
7000
7001 c. Fixed a problem which caused the display to be messed up when the last
7002 line of a multi-line prompt (possibly containing invisible characters)
7003 was longer than the screen width.
7004
7005 d. Fixed a problem with the vi-mode `r' command that occurred on systems with
7006 support for multibyte characters when running in a locale without any
7007 multibyte characters.
7008
7009 ------------------------------------------------------------------------------
7010 This document details the changes between this version, bash-2.05b-alpha1,
7011 and the previous version, bash-2.05a-release.
7012
7013 1. Changes to Bash
7014
7015 a. Some changes to work around inlining differences between compilers.
7016
7017 b. Added more prototypes for internal shell typedefs, to catch argument
7018 passing errors when using pointers to functions.
7019
7020 c. The `cd' builtin now fails in posix mode when a valid directory cannot be
7021 constructed from a relative pathname argument and the $PWD using pathname
7022 canonicalization, and the -P option has not been supplied. Previously,
7023 the shell would attempt to use what the user typed, leading to weird
7024 values for $PWD and discrepancies between the value of $PWD and the
7025 actual working directory.
7026
7027 d. The `cd' builtin now resets $PWD when canonicalization fails but a chdir
7028 to the pathname passed as an argument succeeds (when not in posix mode).
7029
7030 e. The `fc' builtin has been fixed, as POSIX requires, to use the closest
7031 history position in range when given an out-of-range argument.
7032
7033 f. The history file loading code was changed to allow lines to be saved in
7034 the history list from the shell startup files.
7035
7036 g. `history -s args' now works better in compound commands.
7037
7038 h. The tilde expansion code was fixed to better recognize when it's being
7039 invoked in an assignment context, which enables expansion after `='
7040 and `:'.
7041
7042 i. Fixed the command name completion code so a slash is no longer appended
7043 to a single match if there happens to be a directory with that name in
7044 $PWD.
7045
7046 j. Fixed compound array assignment to no longer perform alias expansion, to
7047 allow reserved words as array members, and to not produce extra output
7048 when the `-v' option had been enabled.
7049
7050 k. Fixed the programmable completion code to better handle newlines in lists
7051 of possible completions (e.g., `complete -W').
7052
7053 l. Removed the reserved words from the `bash-builtins' manual page.
7054
7055 m. Parser error reporting now attempts to do a better job of identifying the
7056 token in error rather than doing straight textual analysis.
7057
7058 n. Fixes for Inf/NaN, locales, wide/multibyte characters and zero-length
7059 arguments in the library snprintf(3) replacement.
7060
7061 o. `read -e' no longer does command name completion on the first word on
7062 the line being read.
7063
7064 p. `select' now returns failure if the read of the user's selection fails.
7065
7066 q. Fixed a bug that could cause a core dump when setting $PIPESTATUS.
7067
7068 r. Fixes to not allocate so many job slots when the shell is running a loop
7069 with job control enabled in a subshell of an interactive shell.
7070
7071 s. Fixed a bug in the trap code that caused traps to be inherited by
7072 command substitutions in some cases.
7073
7074 t. Fixed a bug that could cause alias expansion to inappropriately expand
7075 the word following the alias.
7076
7077 u. Fixed a bug in the `kill' builtin that mishandled negative pid arguments.
7078
7079 v. The parser is less lenient when parsing assignment statements where the
7080 characters before the `=' don't comprise a valid identifier.
7081
7082 w. The arithmetic expression evaluation code now honors the setting of the
7083 `-u' option when expanding variable names.
7084
7085 x. Fixed the arithmetic evaluation code to allow array subscripts to be
7086 assigned (`let b[7]=42') and auto-incremented and auto-decremented
7087 (e.g., b[7]++).
7088
7089 y. Reimplemented the existing prompt string date and time expansions using
7090 strftime(3), which changed the output of \@ in some locales.
7091
7092 z. Fixed a bug that could cause a core dump when a special shell variable
7093 (like RANDOM) was converted to an array with a variable assignment.
7094
7095 aa. Fixed a bug that would reset the handler for a signal the user had
7096 trapped to a function that would exit the shell when setting the exit
7097 trap in a non-interactive shell.
7098
7099 bb. Changed the execve(2) wrapper code to check whether or not a failing
7100 command is a directory before looking at whether a `#!' interpreter
7101 failed for some reason.
7102
7103 cc. Fixed a bug in the command printing code so it no longer inserts a `;'
7104 after a newline, which produces a syntax error when reused as input.
7105
7106 dd. The code that expands $PS4 no longer inherits the `-x' flag.
7107
7108 ee. The bash-specific completion functions may now take advantage of the
7109 double-TAB and M-? features of the standard readline completion
7110 functions.
7111
7112 ff. The mail checking code no longer prints a message if the checked file's
7113 size has not increased, even if the access time is less than the modification time.
7114
7115 gg. Rewrote the variable symbol table code: there is now a stack of
7116 contexts, each possibly including a separate symbol table; there can
7117 be more than one temporary environment supplied to nested invocations
7118 of `./source'; the temporary environments no longer require so much
7119 special-case code; shell functions now handle the temporary environment
7120 and local variables more consistently; function scope exit is faster now
7121 that the entire symbol table does not have to be traversed to dispose of
7122 local variables; it is now easier to push vars from the temporary
7123 environment to the shell's variable table in posix mode; some duplicated
7124 code has been removed.
7125
7126 hh. Regularized the error message printing code; builtin_error is now called
7127 more consistently, and common error message strings are handled by small
7128 functions. This should make eventual message translation easier.
7129
7130 ii. Error messages now include the line number in a script when the shell
7131 is not interactive.
7132
7133 jj. Array subscript expansion now takes place even when the array variable is
7134 unset, so side effects will take place.
7135
7136 kk. Fixed a bug in the SICGHLD child-reaping code so that it won't find
7137 jobs already marked as terminated if the OS reuses pids quickly enough.
7138
7139 ll. Fixed a bug that could cause a signal to not interrupt the `wait'
7140 builtin while it was waiting for a background process to terminate.
7141
7142 mm. A couple of changes to make it easier for multiple shells to share history
7143 files using `history -n', `history -r', and `history -w'.
7144
7145 nn. The `getopts' builtin always increments OPTIND to point to the next
7146 option to be handled when an option is returned, whether it's valid
7147 or not, as POSIX 1003.x-2001 requires.
7148
7149 oo. Changed some parts of the expansion code to avoid allocating and
7150 immediately freeing memory without using the results for anything.
7151
7152 pp. The shell now keeps track of $IFS internally, updating its internal map
7153 each time the variable is assigned a new value (or at local scope exit).
7154 This saves thousands of hash lookups for IFS, which, while individually
7155 cheap, add up.
7156
7157 qq. Rewrote the hash table code: searching and insertion are much faster now,
7158 and it uses a better string hashing function; augmented the function
7159 interface to simplify other parts of the code and remove duplicated code
7160
7161 rr. The shell now uses a simple, generic `object cache' for allocating and
7162 caching words and word lists, which were the major users of
7163 malloc/free.
7164
7165 ss. Fixed the assignment statement parsing code to allow whitespace and
7166 newlines in subscripts when performing array element assignment.
7167
7168 tt. The shell now issues many fewer calls to sigprocmask and other signal
7169 masking system calls.
7170
7171 uu. Fixed the `test' and conditional command file comparison operators to
7172 work right when one file has a non-positive timestamp and the other
7173 does not exist.
7174
7175 vv. Fixed some cases where the special characters '\001' and '\177' in the
7176 values of variables or positional parameters caused incorrect expansion
7177 results.
7178
7179 2. Changes to Readline
7180
7181 a. Fixed output of comment-begin character when listing variable values.
7182
7183 b. Added some default key bindings for common escape sequences produced by
7184 HOME and END keys.
7185
7186 c. Fixed the mark handling code to be more emacs-compatible.
7187
7188 d. A bug was fixed in the code that prints possible completions to keep it
7189 from printing empty strings in certain circumstances.
7190
7191 e. Change the key sequence printing code to print ESC as M\- if ESC is a
7192 meta-prefix character -- it's easier for users to understand than \e.
7193
7194 f. Fixed unstifle_history() to return values that match the documentation.
7195
7196 g. Fixed the event loop (rl_event_hook) to handle the case where the input
7197 file descriptor is invalidated.
7198
7199 h. Fixed the prompt display code to work better when the application has a
7200 custom redisplay function.
7201
7202 i. Changes to make reading and writing the history file a little faster, and
7203 to cope with huge history files without calling abort(3) from xmalloc.
7204
7205 j. The vi-mode `S' and `s' commands are now undone correctly.
7206
7207 3. New Features in Bash
7208
7209 a. If set, TMOUT is the default timeout for the `read' builtin.
7210
7211 b. `type' has two new options: `-f' suppresses shell function lookup, and
7212 `-P' forces a $PATH search.
7213
7214 c. New code to handle multibyte characters.
7215
7216 d. `select' was changed to be more ksh-compatible, in that the menu is
7217 reprinted each time through the loop only if REPLY is set to NULL.
7218 The previous behavior is available as a compile-time option.
7219
7220 e. `complete -d' and `complete -o dirnames' now force a slash to be
7221 appended to names which are symlinks to directories.
7222
7223 f. There is now a bindable edit-and-execute-command readline command,
7224 like the vi-mode `v' command, bound to C-xC-e in emacs mode.
7225
7226 g. Added support for ksh93-like [:word:] character class in pattern matching.
7227
7228 h. The $'...' quoting construct now expands \cX to Control-X.
7229
7230 i. A new \D{...} prompt expansion; passes the `...' to strftime and inserts
7231 the result into the expanded prompt.
7232
7233 j. The shell now performs arithmetic in the largest integer size the
7234 machine supports (intmax_t), instead of long.
7235
7236 k. If a numeric argument is supplied to one of the bash globbing completion
7237 functions, a `*' is appended to the word before expansion is attempted.
7238
7239 l. The bash globbing completion functions now allow completions to be listed
7240 with double tabs or if `show-all-if-ambiguous' is set.
7241
7242 m. New `-o nospace' option for `complete' and `compgen' builtins; suppresses
7243 readline's appending a space to the completed word.
7244
7245 n. New `here-string' redirection operator: <<< word.
7246
7247 o. When displaying variables, function attributes and definitions are shown
7248 separately, allowing them to be re-used as input (attempting to re-use
7249 the old output would result in syntax errors).
7250
7251 p. There is a new configuration option `--enable-mem-scramble', controls
7252 bash malloc behavior of writing garbage characters into memory at
7253 allocation and free time.
7254
7255 q. The `complete' and `compgen' builtins now have a new `-s/-A service'
7256 option to complete on names from /etc/services.
7257
7258 r. `read' has a new `-u fd' option to read from a specified file descriptor.
7259
7260 s. Fix the completion code so that expansion errors in a directory name
7261 don't cause a longjmp back to the command loop.
7262
7263 t. Fixed word completion inside command substitution to work a little more
7264 intuitively.
7265
7266 u. The `printf' %q format specifier now uses $'...' quoting to print the
7267 argument if it contains non-printing characters.
7268
7269 v. The `declare' and `typeset' builtins have a new `-t' option. When applied
7270 to functions, it causes the DEBUG trap to be inherited by the named
7271 function. Currently has no effect on variables.
7272
7273 w. The DEBUG trap is now run *before* simple commands, ((...)) commands,
7274 [[...]] conditional commands, and for ((...)) loops.
7275
7276 x. The expansion of $LINENO inside a shell function is only relative to the
7277 function start if the shell is interactive -- if the shell is running a
7278 script, $LINENO expands to the line number in the script. This is as
7279 POSIX-2001 requires.
7280
7281 y. The bash debugger in examples/bashdb has been modified to work with the
7282 new DEBUG trap semantics, the command set has been made more gdb-like,
7283 and the changes to $LINENO make debugging functions work better. Code
7284 from Gary Vaughan.
7285
7286 z. New [n]<&word- and [n]>&word- redirections from ksh93 -- move fds (dup
7287 and close).
7288
7289 aa. There is a new `-l' invocation option, equivalent to `--login'.
7290
7291 bb. The `hash' builtin has a new `-l' option to list contents in a reusable
7292 format, and a `-d' option to remove a name from the hash table.
7293
7294 4. New Features in Readline
7295
7296 a. Support for key `subsequences': allows, e.g., ESC and ESC-a to both
7297 be bound to readline functions. Now the arrow keys may be used in vi
7298 insert mode.
7299
7300 b. When listing completions, and the number of lines displayed is more than
7301 the screen length, readline uses an internal pager to display the results.
7302 This is controlled by the `page-completions' variable (default on).
7303
7304 c. New code to handle editing and displaying multibyte characters.
7305
7306 d. The behavior introduced in bash-2.05a of deciding whether or not to
7307 append a slash to a completed name that is a symlink to a directory has
7308 been made optional, controlled by the `mark-symlinked-directories'
7309 variable (default is the 2.05a behavior).
7310
7311 e. The `insert-comment' command now acts as a toggle if given a numeric
7312 argument: if the first characters on the line don't specify a
7313 comment, insert one; if they do, delete the comment text
7314
7315 f. New application-settable completion variable:
7316 rl_completion_mark_symlink_dirs, allows an application's completion
7317 function to temporarily override the user's preference for appending
7318 slashes to names which are symlinks to directories.
7319
7320 g. New function available to application completion functions:
7321 rl_completion_mode, to tell how the completion function was invoked
7322 and decide which argument to supply to rl_complete_internal (to list
7323 completions, etc.).
7324
7325 h. Readline now has an overwrite mode, toggled by the `overwrite-mode'
7326 bindable command, which could be bound to `Insert'.
7327
7328 i. New application-settable completion variable:
7329 rl_completion_suppress_append, inhibits appending of
7330 rl_completion_append_character to completed words.
7331
7332 j. New key bindings when reading an incremental search string: ^W yanks
7333 the currently-matched word out of the current line into the search
7334 string; ^Y yanks the rest of the current line into the search string,
7335 DEL or ^H deletes characters from the search string.
7336
7337 ------------------------------------------------------------------------------
7338 This document details the changes between this version, bash-2.05a-release,
7339 and the previous version, bash-2.05a-rc1.
7340
7341 1. Changes to Bash
7342
7343 a. Fixed the `printf' builtin so that the variable name supplied as an
7344 argument to a %n conversion must be a valid shell identifier.
7345
7346 b. Improved the random number generator slightly.
7347
7348 c. Changes to configuration to not put -I/usr/include into $CFLAGS, since
7349 it messes up some includes.
7350
7351 d. Corrected description of POSIXLY_CORRECT in man page and info manual.
7352
7353 e. Fixed a couple of cases of incorrect function prototypes that sneaked
7354 through and caused compilation problems.
7355
7356 f. A few changes to avoid potential core dumps in the programmable completion
7357 code.
7358
7359 g. Fixed a configure problem that could cause a non-existent file to show
7360 up in LIBOBJS.
7361
7362 h. Fixed a configure problem that could cause siglist.o to not be built when
7363 required.
7364
7365 i. Changes to the strtoimax and strtoumax replacement functions to work
7366 around buggy compilers.
7367
7368 j. Fixed a problem with the snprintf replacement function that could
7369 potentially cause a core dump.
7370
7371 2. Changes to Readline
7372
7373 a. Fixed a locale-specific problem in the vi-mode `goto mark' command.
7374
7375 b. Fixed Makefile to not put -I/usr/include into CFLAGS, since it can cause
7376 include file problems.
7377
7378 ------------------------------------------------------------------------------
7379 This document details the changes between this version, bash-2.05a-rc1,
7380 and the previous version, bash-2.05a-beta1.
7381
7382 1. Changes to Bash
7383
7384 a. Fixed the snprintf replacement to correctly implement the `alternate form'
7385 of the %g and %G conversions.
7386
7387 b. Fixed snprintf to correctly handle the optional precision with the %g and
7388 %G conversions.
7389
7390 c. Fixed the arithmetic evaluation code to correct the values of `@' and `_'
7391 when translating base-64 constants (they were backwards).
7392
7393 d. New library functions for formatting long and long long ints.
7394
7395 e. Fixed a few places where negative array subscripts could have occurred,
7396 mostly as the result of systems using signed characters.
7397
7398 f. Fixed a few places that assumed a pid_t was no wider than an int.
7399
7400 g. Fixed the `maildir' mail checking code to work on systems where a
7401 `struct stat' doesn't include an `st_blocks' member.
7402
7403 h. Fixed snprintf to make `unsigned long long' conversion formats (%llu)
7404 work better.
7405
7406 i. Fixed snprintf to not print a sign when asked to do an unsigned conversion.
7407
7408 j. Made configure changes to avoid compiling empty source files in lib/sh.
7409
7410 k. New replacement functions (if necessary) for strtoull, strtoll, strtoimax,
7411 strtoumax.
7412
7413 l. The `printf' builtin now handles the `ll' and `j' length modifiers
7414 directly, since they can affect the type and width of the argument
7415 passed to printf(3).
7416
7417 m. Renamed a number of the bash-specific autoconf macros in aclocal.m4 to
7418 have more systematic naming, with accompanying changes to configure.in.
7419
7420 n. Fixed snprintf to handle long doubles and the %a/%A conversions by
7421 falling back to sprintf, as long as sprintf supports them.
7422
7423 o. Fixed return value from vsnprintf/snprintf to be the number of characters
7424 that would have been printed, even if that number exceeds the buffer
7425 size passed as an argument.
7426
7427 p. Bash no longer attempts to define its own versions of some ctype macros
7428 if they are implemented as functions in libc but not as macros in
7429 <ctype.h>.
7430
7431 q. Changed the variable printing code (used by `set', `export', etc.) to
7432 not use the $'...' syntax when in posix mode, since that caused
7433 interoperability problems with other shells (most notably with autoconf).
7434 When not in posix mode, it uses $'...' if the string to be printed
7435 contains non-printing characters and regular single quotes otherwise.
7436
7437 r. snprintf now recognizes the %F conversion.
7438
7439 s. Fixed a bug that could cause the wrong status to be returned by a shell
7440 function when the shell is compiled without job control and a null
7441 command containing a command substutition was executed in the function.
7442
7443 t. When in posix mode, the default value for MAILCHECK is 600.
7444
7445 u. Bash only initializes FUNCNAME, GROUPS, and DIRSTACK as special variables
7446 if they're not in the initial environment.
7447
7448 v. If SECONDS appears in the initial environment with a valid integer value,
7449 bash uses that as the starting value, as if an assignment had been
7450 performed.
7451
7452 w. Bash no longer auto-exports HOME, PATH, SHELL, or TERM, even though it
7453 gives them default values if they don't appear in the initial environment.
7454
7455 x. Bash no longer auto-exports HOSTNAME, HOSTTYPE, MACHTYPE, or OSTYPE,
7456 even if it assigns them default values.
7457
7458 y. Bash no longer removes the export attribute from SSH_CLIENT or SSH2_CLIENT
7459 if they appear in the initial environment.
7460
7461 z. Bash no longer attempts to discover if it's being run by sshd in order to
7462 run the startup files. If the SSH_SOURCE_BASHRC is uncommented in
7463 config-top.h it will attempt to do so as previously, but that's commented
7464 out in the distributed version.
7465
7466 aa. Fixed a typo in the code that tests for LC_NUMERIC.
7467
7468 bb. The POSIXLY_CORRECT shell variable and its effects are now documented.
7469
7470 cc. Some changes to several of the support shell scripts included in the
7471 definitions to try to avoid race conditions and attacks.
7472
7473 dd. Several changes to avoid warnings from `gcc -Wall'.
7474
7475 ee. Fixed a problem with the `unset' builtin that could cause incorrect
7476 results if asked to unset a variable and an array subscript in the
7477 same command.
7478
7479 ff. A few changes to the shell's temporary file creation code to avoid
7480 potential file descriptor leaks and to prefer the system's idea of
7481 the temporary directory to use.
7482
7483 gg. Fixes to build with the C alloca in lib/malloc/alloca.c if the system
7484 requires it but the shell has been configured --without-bash-malloc.
7485
7486 hh. Updated the documentation to note that only interactive shells resend
7487 SIGHUP to all jobs before exiting.
7488
7489 ii. Fixes to only pass unquoted tilde words to tilde_expand, rather than
7490 rely on tilde_expand or getpwnam(3) to handle the quotes (MacOS 10.x
7491 will remove backslashes in any login name passed to getpwnam(3)).
7492
7493 jj. Small change from Paul Eggert to make LINENO right in commands run with
7494 `bash -c'.
7495
7496 2. New Features in Bash
7497
7498 a. The `printf' builtin now handles the %a and %A conversions if they're
7499 implemented by printf(3).
7500
7501 b. The `printf' builtin now handles the %F conversion (just about like %f).
7502
7503 c. The `printf' builtin now handles the %n conversion like printf(3). The
7504 corresponding argument is the name of a shell variable to which the
7505 value is assigned.
7506
7507 3. Changes to Readline
7508
7509 a. Fixed a few places where negative array subscripts could have occurred.
7510
7511 b. Fixed the vi-mode code to use a better method to determine the bounds of
7512 the array used to hold the marks.
7513
7514 c. Fixed the defines in chardefs.h to work better when chars are signed.
7515
7516 d. Fixed configure.in to use the new names for bash autoconf macros.
7517
7518 e. Readline no longer attempts to define its own versions of some ctype
7519 macros if they are implemented as functions in libc but not as macros in
7520 <ctype.h>.
7521
7522 f. Fixed a problem where rl_backward could possibly set point to before
7523 the beginning of the line.
7524
7525 ------------------------------------------------------------------------------
7526 This document details the changes between this version, bash-2.05a-beta1,
7527 and the previous version, bash-2.05a-alpha1.
7528
7529 1. Changes to Bash
7530
7531 a. Fixed a bug in the evaluation of arithmetic `for' statements when the
7532 expanded expression is NULL.
7533
7534 b. Fixed an unassigned variable problem in the redirection printing code.
7535
7536 c. Added more prototypes to extern function declarations in the header
7537 files and to static function declarations in C source files.
7538
7539 d. Make sure called functions have a prototype in scope, to get the arguments
7540 and return values right instead of casting. Removed extern function
7541 declarations from C source files that were already included in header
7542 files.
7543
7544 e. Changed some function arguments to use function typedefs in general.h so
7545 the prototypes can be checked. The only use of Function and VFunction
7546 now is for unwind-protects.
7547
7548 f. More const changes to function arguments and appropriate variables.
7549
7550 g. Changed the mail checking support to handle `maildir'-style mail
7551 directories.
7552
7553 h. Augmented the bash malloc to pass in the file and line number information
7554 for each malloc, realloc, and free. This should result in better error
7555 messages.
7556
7557 i. The `old' gnu malloc is no longer a configuration option.
7558
7559 j. Augmented the bash malloc with optional tracing and registering allocated
7560 and freed memory.
7561
7562 k. Prompt string decoding now saves and restores the value of $? when it
7563 expands the prompt string, so command substitutions don't change $?.
7564
7565 i. Array indices are now `long', since shell arithmetic is performed as long,
7566 and the internal arrayind_t type is used consistently.
7567
7568 j. Some more `unsigned char *' fixes from Paul Eggert.
7569
7570 k. Fixed a bad call to builtin_error that could cause core dumps when making
7571 local variables.
7572
7573 l. `return' may no longer be used to terminate a `select' command, for
7574 compatibility with ksh.
7575
7576 m. Changed code that reads octal numbers to do a better job of detecting
7577 overflows.
7578
7579 n. The time formatting code no longer uses absolute indices into a buffer,
7580 because the buffer size changes depending on the size of a `time_t'.
7581
7582 o. `umask' now prints four digits when printing in octal mode, for
7583 compatibility with other shells.
7584
7585 p. Lots of changes to the `printf' builtin from Paul Eggert: it handles `L'
7586 formats and long doubles better, and internal functions have been
7587 simplified where appropriate.
7588
7589 q. Some `time_t' fixes for machines were a time_t is bigger than a long.
7590
7591 r. Replaced some bash-specific autoconf macros with standard equivalents.
7592
7593 s. Improvmed the code that constructs temporary filenames to make the
7594 generated names a bit more random.
7595
7596 t. Added code that checks for ascii before calling any of the is* ctype
7597 functions.
7598
7599 u. Changed some places where a `char' was used as an array subscript to use
7600 `unsigned char', since a `char' can be negative if it's signed by default.
7601
7602 v. Lots of changes to the `ulimit' builtin from Paul Eggert to add support
7603 for the new POSIX-200x RLIM_SAVED_CUR and RLIM_SAVED_MAX values and
7604 simplify the code.
7605
7606 w. `ulimit' now prints the description of a resource in any error message
7607 relating to fetching or setting that resource's limits.
7608
7609 x. The `snprintf' replacement now computes maximum values at compile
7610 time rather than using huge constants for things like long long.
7611
7612 y. Interactive shells now ignore `set -n'.
7613
7614 z. Changed the malloc bookkeeping information so that it's now 8 bytes
7615 instead of 12 on most 32-bit machines (saving 4 bytes per allocation),
7616 restoring 8-byte alignment.
7617
7618 aa. The malloc error reporting code now attempts to print the file and line
7619 number of the call that caused the error.
7620
7621 bb. Changed the redirection error reporting code to catch EBADF errors and
7622 report the file descriptor number rather than the file being redirected
7623 to or from (e.g., things like `exec 4242<x' where 4242 is an out-of-range
7624 file descriptor).
7625
7626 cc. `printf', `echo -e', and the $'...' code now process only two hex digits
7627 after a `\x' escape sequence for compatibility with other shells, and
7628 the documentation was changed to note that the octal and hex escape
7629 sequences result in an eight-bit value rather than strict ASCII.
7630
7631 2. Changes to Readline
7632
7633 a. The completion code now attempts to do a better job of preserving the
7634 case of the word the user typed if ignoring case in completions.
7635
7636 b. Readline defaults to not echoing the input and lets the terminal
7637 initialization code enable echoing if there is a controlling terminal.
7638
7639 c. The key binding code now processes only two hex digits after a `\x'
7640 escape sequence, and the documentation was changed to note that the
7641 octal and hex escape sequences result in an eight-bit value rather
7642 than strict ASCII.
7643
7644 3. New Features in Bash
7645
7646 a. The builtin `ulimit' now takes two new non-numeric arguments: `hard',
7647 meaning the current hard limit, and `soft', meaning the current soft
7648 limit, in addition to `unlimited'
7649
7650 b. `ulimit' now prints the option letter associated with a particular
7651 resource when printing more than one limit.
7652
7653 c. `ulimit' prints `hard' or `soft' when a value is not `unlimited' but is
7654 one of RLIM_SAVED_MAX or RLIM_SAVED_CUR, respectively.
7655
7656 4. New Features in Readline
7657
7658 a. New bindable variable `history-preserve-point'. If set, the history
7659 code attempts to place the user at the same location on each history
7660 line retrieved with previous-history or next-history.
7661
7662 ------------------------------------------------------------------------------
7663 This document details the changes between this version, bash-2.05a-alpha1,
7664 and the previous version, bash-2.05-release.
7665
7666 1. Changes to Bash
7667
7668 a. Better checks in the redirection code for write errors.
7669
7670 b. bashbug now uses $TMPDIR, defaulting to /tmp, and uses mktemp(1) more
7671 portably.
7672
7673 c. System-specific configuration changes for: Interix, OpenBSD, FreeBSD,
7674 MacOS X.
7675
7676 d. Some more `const' cleanups through the code.
7677
7678 e. Fixed a typo in the /dev/fd redirection code, better checks for valid
7679 numeric fds in /dev/fd.
7680
7681 f. Fixed many parts of the shell to handle integer overflow more gracefully
7682 and to do more stringent checks for valid numbers.
7683
7684 g. Fixed mksignames to include config.h.
7685
7686 h. Fixed an uninitialized variable problem that could cause the shell to core
7687 dump when replacing characters in a string.
7688
7689 i. New mechanism for updating the patch level when official patches are
7690 released (patchlevel.h).
7691
7692 j. configure.in changed to no longer require external files _distribution and
7693 _patchlevel.
7694
7695 k. Fixed non-interactive shell initialization problem when bash started as
7696 `bash -i filename'.
7697
7698 l. Fixed printf builtin conversion error handling to be POSIX.2-conformant.
7699
7700 m. autoconf-2.52 is now used to build configure; autoconf-2.50 or newer is
7701 required. Some of the bash-specific macros were removed, since they are
7702 now standard.
7703
7704 n. Startup files and files read with source or `.' are no longer required to
7705 be regular files.
7706
7707 o. Fixed core dump in builtin printf when user-supplied precision or field
7708 width is 0.
7709
7710 p. Fixed builtin printf to treat a negative field width as a positive field
7711 width with left-justification.
7712
7713 r. New unwind-protect implementation from Paul Eggert.
7714
7715 s. Fixed an inadvertently-unclosed comment in the bash completion code that
7716 caused programmable completions to not add trailing slashes or spaces to
7717 completions.
7718
7719 t. Fixed the process substitution code to cope better when stdin is closed.
7720
7721 v. Fixes, mostly from Paul Eggert, for a few possible buffer overflows in
7722 the shell.
7723
7724 w. Fixes from Paul Eggert to avoid most of the type casts in the shell code,
7725 and use more appropriate types for a number of variables.
7726
7727 x. Command substitution no longer inherits the DEBUG trap.
7728
7729 y. Some fixes to the process substitution code on machines without /dev/fd so
7730 that named pipes are not removed inappropriately.
7731
7732 z. The loadable `getconf' builtin is now much more complete, and will become
7733 part of the shell in the future.
7734
7735 aa. The select command no longer terminates on a `return', so it can be used
7736 to return from an enclosing function (as ksh does it).
7737
7738 bb. Fixed the extended pattern matching code to behave better when presented
7739 with incorrectly-formed patterns.
7740
7741 cc. Some changes were made with the intent of making cross-compilation easier.
7742
7743 dd. The network code (/dev/tcp and /dev/udp redirections) uses getaddrinfo(3)
7744 if it's available, which adds support for IPv6.
7745
7746 ee. Subshells of login shells no longer source ~/.bash_logout when they exit.
7747
7748 ff. Fixes so that subshells don't exit inappropriately if the -e option has
7749 been set.
7750
7751 gg. Restricted shells no longer allow functions to be exported.
7752
7753 hh. Changes to the pattern matching code so extended pattern matching works
7754 on systems with deficient shared library implementations, like MacOS X.
7755
7756 ii. Better error messages when a script with a leading `#!interp' fails
7757 to execute because of problems with `interp'.
7758
7759 jj. Fixed `compgen' to handle the `-o default' option better.
7760
7761 kk. Fixed the job control code to force an asynchronous process's standard
7762 input to /dev/null only if job control is not active.
7763
7764 ll. Fixed a possible infinite recursion problem when `fc ""=abc' (a null
7765 pattern) is used to re-execute a previous command.
7766
7767 mm. Fixed `declare [-a] var=value' to assign VALUE to element 0 if VAR is an
7768 array variable. Similarly for `declare [-a] var[N]=value'. This is like
7769 ksh93.
7770
7771 nn. Fixed a bug that caused `read -a aname' to work even if ANAME had been
7772 declared readonly.
7773
7774 oo. Fixed a possible integer overflow problem when constructing names for
7775 temporary files.
7776
7777 2. New Features in Bash
7778
7779 a. Added support for DESTDIR installation root prefix, so you can do a
7780 `make install DESTDIR=bash-root' and do easier binary packaging.
7781
7782 b. Added support for builtin printf "'" flag character as per latest POSIX
7783 drafts.
7784
7785 c. Support for POSIX.2 printf(1) length specifiers `j', `t', and `z' (from
7786 ISO C99).
7787
7788 d. New autoconf macro, RL_LIB_READLINE_VERSION, for use by other applications
7789 (bash doesn't use very much of what it returns).
7790
7791 e. `set [-+]o nolog' is recognized as required by the latest POSIX drafts,
7792 but ignored.
7793
7794 f. New read-only `shopt' option: login_shell. Set to non-zero value if the
7795 shell is a login shell.
7796
7797 g. New `\A' prompt string escape sequence; expands to time in 24 HH:MM format.
7798
7799 h. New `-A group/-g' option to complete and compgen; does group name
7800 completion.
7801
7802 i. New `-t' option to `hash' to list hash values for each filename argument.
7803
7804 j. New [-+]O invocation option to set and unset `shopt' options at startup.
7805
7806 k. configure's `--with-installed-readline' option now takes an optional
7807 `=PATH' suffix to set the root of the tree where readline is installed
7808 to PATH.
7809
7810 l. The ksh-like `ERR' trap has been added. The `ERR' trap will be run
7811 whenever the shell would have exited if the -e option were enabled.
7812 It is not inherited by shell functions.
7813
7814 m. `readonly', `export', and `declare' now print variables which have been
7815 given attributes but not set by assigning a value as just a command and
7816 a variable name (like `export foo') when listing, as the latest POSIX
7817 drafts require.
7818
7819 n. `bashbug' now requires that the subject be changed from the default.
7820
7821 o. configure has a new `--enable-largefile' option, like other GNU utilities.
7822
7823 p. `for' loops now allow empty word lists after `in', like the latest POSIX
7824 drafts require.
7825
7826 3. Changes to Readline
7827
7828 a. More `const' and type casting fixes.
7829
7830 b. Changed rl_message() to use vsnprintf(3) (if available) to fix buffer
7831 overflow problems.
7832
7833 c. The completion code no longer appends a `/' or ` ' to a match when
7834 completing a symbolic link that resolves to a directory name, unless
7835 the match does not add anything to the word being completed. This
7836 means that a tab will complete the word up to the full name, but not
7837 add anything, and a subsequent tab will add a slash.
7838
7839 d. Fixed a trivial typo that made the vi-mode `dT' command not work.
7840
7841 e. Fixed the tty code so that ^S and ^Q can be inserted with rl_quoted_insert.
7842
7843 f. Fixed the tty code so that ^V works more than once.
7844
7845 g. Changed the use of __P((...)) for function prototypes to PARAMS((...))
7846 because the use of __P in typedefs conflicted g++ and glibc.
7847
7848 4. New Features in Readline
7849
7850 a. Added extern declaration for rl_get_termcap to readline.h, making it a
7851 public function (it was always there, just not in readline.h).
7852
7853 b. New #defines in readline.h: RL_READLINE_VERSION, currently 0x0402,
7854 RL_VERSION_MAJOR, currently 4, and RL_VERSION_MINOR, currently 2.
7855
7856 c. New readline variable: rl_readline_version, mirrors RL_READLINE_VERSION.
7857
7858 d. New bindable boolean readline variable: match-hidden-files. Controls
7859 completion of files beginning with a `.' (on Unix). Enabled by default.
7860
7861 e. The history expansion code now allows any character to terminate a
7862 `:first-' modifier, like csh.
7863
7864 f. The incremental search code remembers the last search string and uses
7865 it if ^R^R is typed without a search string.
7866
7867 ------------------------------------------------------------------------------
7868 This document details the changes between this version, bash-2.05-release,
7869 and the previous version, bash-2.05-beta2.
7870
7871 1. Changes to Bash
7872
7873 a. Make sure we note that the first line of a multi-line command was not
7874 saved in the history if the tests for HISTCONTROL succeed, but the
7875 HISTIGNORE check fails.
7876
7877 b. Fixed a bug in the pattern matching code that caused `[' to be treated
7878 as a special character inside a `[...]' bracket expression.
7879
7880 c. Fixed a bug in the pattern matching code that caused `]' to terminate
7881 a bracket expression even if it was the first character after the `['
7882 (or a leading `!' or `^').
7883
7884 d. Made a small change to report a more user-friendly error message if
7885 execve(2) fails because of an error with the interpreter in a script
7886 with a leading `#! interpreter'.
7887
7888 e. If the OS does not support an exec(2) magic number of `#!', make sure we
7889 have a non-null interpreter name before attempting to execute it.
7890
7891 f. Fixed a bug that caused the shell process to end up in a different
7892 process group than the controlling terminal if a job-control shell was
7893 run with `exec' in the startup files.
7894
7895 g. When started in POSIX mode, either by `bash --posix', `bash -o posix', or
7896 `sh', $SHELLOPTS includes `posix' and POSIXLY_CORRECT is set.
7897
7898 h. Fixed a problem that caused the `\W' prompt string escape sequence to
7899 expand to nothing when $PWD was `//'.
7900
7901 i. The `bashbug' shell script no longer uses $(...) command substitution.
7902
7903 j. When `set' is invoked without options in POSIX mode, it no longer prints
7904 the names and definitions of shell functions.
7905
7906 2. Changes to Readline
7907
7908 a. rl_set_paren_blink_timeout() is now documented.
7909
7910 b. Corrected history.3 man page: `$' is not in the default value of
7911 history_word_delimiters.
7912
7913 c. If a hook function assigned to rl_event_hook sets rl_done to a non-zero
7914 value, rl_read_key() now immediately returns '\n' (which is assumed to
7915 be bound to accept-line).
7916
7917 3. New Features in Bash
7918
7919 a. The `>&word' redirection now works in POSIX mode as it does by default,
7920 since POSIX.2 leaves it unspecified.
7921
7922 ------------------------------------------------------------------------------
7923 This document details the changes between this version, bash-2.05-beta2,
7924 and the previous version, bash-2.05-beta1.
7925
7926 1. Changes to Bash
7927
7928 a. Fixed a bug in the arithmetic evaluation code so that a^=b is supported.
7929
7930 b. Fixed startup so posixly_correct is retained across subshells begun to
7931 execute scripts without a leading `#!'.
7932
7933 c. Fixed a bug that caused $(< file) to not work in a (...) subshell.
7934
7935 d. Added config support for Linux running on the IBM S390.
7936
7937 e. Fixed a bug that caused bash to get its input pointer out of sync when
7938 reading commands through a pipe and running a command with standard
7939 input redirected from a file.
7940
7941 f. Made a change so that command completion now makes about half as many
7942 stat(2) calls when searching the $PATH.
7943
7944 g. Fixed a bug that caused variable assignments preceding `return' to not
7945 be propagated to the shell environment in POSIX mode.
7946
7947 h. Fixed a bug with ${parameter[:]?word} -- tilde expansion was not performed
7948 on `word'.
7949
7950 i. In POSIX mode, `break' and `continue' do not complain and return success
7951 if called when the shell is not executing a loop.
7952
7953 j. Fixed `bash -o posix' to work the same as `bash --posix'.
7954
7955 k. Fixed a bug where variable assignments preceding `eval' or `source/.'
7956 would not show up in the environment exported to subshells run by the
7957 commands.
7958
7959 l. In POSIX mode, shells started to execute command substitutions inherit
7960 the value of the `-e' option from their parent shell.
7961
7962 m. In POSIX mode, aliases are expanded even in non-interactive shells.
7963
7964 n. Changed some of the job control messages to display the text required by
7965 POSIX.2 when the shell is in POSIX mode.
7966
7967 o. Fixed a bug in `test' that caused it to occasionally return incorrect
7968 results when non-numeric arguments were supplied to `-t'.
7969
7970 2. Changes to Readline
7971
7972 a. Some changes were made to avoid gcc warnings with -Wall.
7973
7974 b. rl_get_keymap_by_name now finds keymaps case-insensitively, so
7975 `set keymap EMACS' works.
7976
7977 c. The history file writing and truncation functions now return a useful
7978 status on error.
7979
7980 d. Fixed a bug that could cause applications to dereference a NULL pointer
7981 if a NULL second argument was passed to history_expand().
7982
7983 3. New Features in Bash
7984
7985 a. doc/readline.3 has been moved to the readline distribution.
7986
7987 4. New Features in Readline
7988
7989 a. New function, rl_get_screen_size (int *rows, int *columns), returns
7990 readline's idea of the screen dimensions.
7991
7992 b. The timeout in rl_gather_tyi (readline keyboard input polling function)
7993 is now settable via a function (rl_set_keyboard_input_timeout()).
7994
7995 c. Renamed the max_input_history variable to history_max_entries; the old
7996 variable is maintained for backwards compatibility.
7997
7998 d. The list of characters that separate words for the history tokenizer is
7999 now settable with a variable: history_word_delimiters. The default
8000 value is as before.
8001
8002 ------------------------------------------------------------------------------
8003 This document details the changes between this version, bash-2.05-beta1,
8004 and the previous version, bash-2.05-alpha1.
8005
8006 1. Changes to Bash
8007
8008 a. Changes to allow shared library and object building on the GNU Hurd.
8009
8010 b. Fixes to the way exported functions are placed into the environment and
8011 cached.
8012
8013 c. The globbing library once again respects locales when processing ranges
8014 in bracket expressions while doing pattern matching.
8015
8016 d. System-specific configuration changes for: Tru 64, Interix
8017
8018 e. Bashbug now uses /usr/bin/editor as one of the editing alternatives, and
8019 will use mktemp(1) or tempfile(1), if present, for temporary file creation.
8020
8021 f. Bash no longer performs a binary file check on a script argument that's
8022 really a tty (like /dev/fd/0 or /dev/stdin).
8023
8024 g. Fixed a bug in the execution of shell scripts that caused the effects of
8025 $BASH_ENV to be undone in some cases.
8026
8027 h. Fixed several bugs that made `bash [-i] /dev/stdin' not work correctly.
8028
8029 i. Several changes to the job control code to avoid some signal state
8030 manipulation.
8031
8032 j. The Bash malloc no longer blocks signals as often, which should make it
8033 faster.
8034
8035 k. Fixed a parsing bug that did not allow backslash to escape a single quote
8036 inside a $'...' construct.
8037
8038 l. Fixed a bug that caused things like ${var:=$'value'} to be parsed
8039 incorrectly. This showed up in newer versions of autoconf.
8040
8041 m. Fixed a bug in the bash-specific readline initialization that caused
8042 key bindings to bash-specific function names appearing in .inputrc to
8043 not be honored.
8044
8045 n. Bash now sets the file descriptor it uses to save the file descriptor
8046 opened on a shell script to close on exec.
8047
8048 o. Fixed a bug in the prompt string decoding that caused it to misbehave
8049 when presented an octal sequence of fewer than three characters.
8050
8051 p. Fixed the `test' builtin to return an error if `[' is supplied a single
8052 argument that is not `]'.
8053
8054 q. Fixed a bug that caused subshells started to run executable shell scripts
8055 without a leading `#!' to incorrectly inherit an argument list preceding
8056 a shell builtin (like such a script called from a script sourced with `.',
8057 where there were variable assignments preceding the `.' command)
8058
8059 r. Fixed a bug that caused changes to variables supplied in an assignment
8060 statement preceding a shell builtin to not be honored (like a script
8061 run with `.').
8062
8063 s. HOSTTYPE, OSTYPE, and MACHTYPE are set only if they do not have values
8064 when the shell is started.
8065
8066 t. Fixed a bug that caused SIGINT to kill shell scripts after the script
8067 called `wait'.
8068
8069 u. The `fc' builtin now tries to create its temporary files in the directory
8070 named by $TMPDIR.
8071
8072 v. Bash no longer calls any Readline functions or uses any Readline variables
8073 not declared in readline.h.
8074
8075 w. Fixed a bug that caused some substitutions involving $@ to not be split
8076 correctly, especially expansions of the form ${paramterOPword}.
8077
8078 x. SSH2_CLIENT is now treated like SSH_CLIENT and not auto-exported if it
8079 appears in the initial environment.
8080
8081 y. Fixed a couple of problems with shell scripts without a leading `#!'
8082 being executed out of shell functions that could cause core dumps if
8083 such a script attempted to execute `return'.
8084
8085 z. Fixed a problem with the `-nt' and `-ot' binary operators for the
8086 `test/[' builtin and the `[[' conditional command that caused wrong
8087 return values if one of the file arguments did not exist.
8088
8089 aa. Fixed a bug that caused non-interactive shells which had previously
8090 executed `shopt -s expand_aliases' to fail to expand aliases in a
8091 command like `(command) &'.
8092
8093 2. Changes to Readline
8094
8095 a. Changes to make most (but not yet all -- there is still crlf()) of the
8096 exported readline functions declared in readline.h have an rl_ prefix.
8097
8098 b. More `const' changes in function arguments, mostly for completion
8099 functions.
8100
8101 c. Fixed a bug in rl_forward that could cause the point to be set to before
8102 the beginning of the line in vi mode.
8103
8104 d. Fixed a bug in the callback read-char interface to make it work when a
8105 readline function pushes some input onto the input stream with
8106 rl_execute_next (like the incremental search functions).
8107
8108 e. Fixed a file descriptor leak in the history file manipulation code that
8109 was tripped when attempting to truncate a non-regular file (like
8110 /dev/null).
8111
8112 f. Some existing variables are now documented and part of the public
8113 interface (declared in readline.h): rl_explict_arg, rl_numeric_arg,
8114 rl_editing_mode, rl_last_func.
8115
8116 g. Renamed rltty_set_default_bindings to rl_tty_set_default_bindings and
8117 crlf to rl_crlf, so there are no public functions declared in readline.h
8118 without an `rl_' prefix. The old functions still exist for backwards
8119 compatibility.
8120
8121 3. New Features in Bash
8122
8123 a. A new loadable builtin, realpath, which canonicalizes and expands symlinks
8124 in pathname arguments.
8125
8126 b. When `set' is called without options, it prints function definitions in a
8127 way that allows them to be reused as input. This affects `declare' and
8128 `declare -p' as well.
8129
8130 4. New Features in Readline
8131
8132 a. New application-callable function rl_set_prompt(const char *prompt):
8133 expands its prompt string argument and sets rl_prompt to the result.
8134
8135 b. New application-callable function rl_set_screen_size(int rows, int cols):
8136 public method for applications to set readline's idea of the screen
8137 dimensions.
8138
8139 c. The history example program (examples/histexamp.c) is now built as one
8140 of the examples.
8141
8142 ------------------------------------------------------------------------------
8143 This document details the changes between this version, bash-2.05-alpha1,
8144 and the previous version, bash-2.04-release.
8145
8146 1. Changes to Bash
8147
8148 a. A fix was made to allow newlines in compond array assignments.
8149
8150 b. configure now checks for real-time signals with unusable values.
8151
8152 c. Interactive shells no longer exit if a substitution fails because of an
8153 unset variable within a sourced file.
8154
8155 d. Fixed a problem with incorrect matching of extended glob patterns when
8156 doing pattern substitution.
8157
8158 e. `{' is now quoted by the completion code when it appears in a filename.
8159
8160 f. Fixed an error in pattern matching that caused the matcher to not
8161 correctly skip the rest of a bracket expression after a character
8162 matched.
8163
8164 g. Fixed a bug in the IFS word splitting code to make a non-whitespace IFS
8165 character preceded by IFS whitespace part of the current delimiter rather
8166 than generating a separate field.
8167
8168 h. The {!prefix@} expansion now generates separate words, analogous to $@,
8169 when double-quoted.
8170
8171 i. Command substitution now ignores NUL bytes in the command output, and the
8172 parser ignores them on input.
8173
8174 j. A fix was made to the job control code to prevent hanging processes when
8175 the shell thinks background processes are running but the kernel returns
8176 -1/ECHILD from waitpid().
8177
8178 k. `pwd' now prints an error message if the write fails when displaying the
8179 current directory.
8180
8181 l. When in POSIX mode, the shell prints trap dispostions without a leading
8182 `SIG' in the signal specification.
8183
8184 m. Fixed a parser bug that caused the current command's line count to be
8185 messed up by a compound array assignment.
8186
8187 n. Fixed a bug in the unwind-protect code that caused bad behavior on machines
8188 where ints and pointers are not the same size.
8189
8190 o. System-specific configure changes for: MacOS X.
8191
8192 p. Changes for Cygwin to translate \r\n and \r to \n and to set file
8193 descriptors used for reading input to text mode in various places.
8194
8195 q. Fixed a bug that caused `!' to occasionally not be honored when in
8196 a (...) subshell.
8197
8198 r. Bash no longer assumes that getcwd() will return any useful error message
8199 in the buffer passed as an argument if the call fails.
8200
8201 s. The `source', `.', and `fc' builtins no longer check whether a file is
8202 binary before reading commands from it.
8203
8204 t. Subshells no longer turn off job control when they exit, since that
8205 sometimes resulted in the terminal being reset to the wrong process
8206 group.
8207
8208 u. The history code no longer tries to save the second and subsequent lines
8209 of a multi-line command if the first line was not saved.
8210
8211 v. The history saving code now does a better job of saving blank lines in a
8212 multi-line command.
8213
8214 w. Removed a `feature' that made `ulimit' silently translate `unlimited' to
8215 the current hard limit, which obscured some kernel error returns.
8216
8217 x. Fixed the grammar so that `}' is recognized as a reserved word after
8218 another reserved word, rather than requiring a `;' or newline. This
8219 means that constructs like
8220
8221 { { echo a b c ; } }
8222
8223 work as expected.
8224
8225 y. Conditional commands ([[...]]) now perform tilde expansion on their
8226 arguments.
8227
8228 z. Noted in the documentation that `set -a' will cause functions to be
8229 exported if they are defined after `set -a' is executed.
8230
8231 aa. When an interactive login shell starts, if $PWD and $HOME refer to the
8232 same directory but are not the same string, $PWD is set to $HOME.
8233
8234 bb. Fixed `printf' to handle invalid floating point numbers better.
8235
8236 cc. Temporary files are now created with random filenames, to improve security.
8237
8238 dd. The readline initialization code now binds the custom bash functions and
8239 key bindings after the readline defaults are set up.
8240
8241 ee. Fixed the `source' builtin to no longer overwrite a shell function's
8242 argument list, even if the sourced file changes the positional parameters.
8243
8244 ff. A bug fix was made in the expansion of `$*' in contexts where it should
8245 not be split, like assignment statements.
8246
8247 gg. Fixed a bug in the parameter substring expansion to handle conditional
8248 arithmetic expressions ( exp ? val1 : val2 ) without cutting the expression
8249 off at the wrong `:'.
8250
8251 hh. The `<>' redirection is no longer subject to the current setting of
8252 `noclobber', as POSIX.2 specifies.
8253
8254 ii. Fixed a bug in the conditional command parsing code that caused expressions
8255 in parentheses to occasionally be parsed incorrectly.
8256
8257 jj. Fixed a bug in the ((...)) arithmetic command to allow do...done or
8258 {...} to follow the )) without an intervening list terminator.
8259
8260 kk. `printf' now treats `\E' the same as `\e' when performing backslash escape
8261 expansion for the `%b' format specifier.
8262
8263 ll. When in POSIX mode, the shell no longer searches the current directory for
8264 a file to be sourced with `.' or `source' if `.' is not in $PATH.
8265
8266 mm. Interactive comments are no longer turned off when POSIX mode is disabled.
8267
8268 nn. The UID, EUID, HOSTNAME variables are not set if they are in the shell's
8269 environment when it starts up.
8270
8271 oo. Fixed a bug in the `command' builtin so the effect of a command like
8272 `command exec 4<file' is as if the `command' had been omitted.
8273
8274 pp. ${foo[@]} and ${foo[*]} now work as in ksh93 if `foo' is not an array
8275 variable.
8276
8277 qq. ${#foo[X]}, where X is 0, @, or *, now work as in ksh93 if `foo' is not
8278 an array variable.
8279
8280 rr. The shell's idea of an absolute pathname now takes into account a
8281 possible drive specification on Cygwin and other Windows systems.
8282
8283 ss. Fixed a bug which caused incorrect parsing of some multi-character
8284 constructs if they were split across input lines with backslash-newline
8285 line continuation.
8286
8287 tt. Fixed a bug that caused restricted shell mode to be set inappropriately
8288 when trying to execute a shell script without a leading `#!'.
8289
8290 uu. Shell function definitions no longer require that the body be a group
8291 command ( {...} ), as POSIX.2 requires.
8292
8293 vv. The `cd' and `pwd' builtins now process symlinks in pathnames internally
8294 and should require many fewer calls to getcwd().
8295
8296 ww. Fixed a bug that caused a pipeline's process group to be set incorrectly
8297 if one of the pipeline elements contained a command substitution.
8298
8299 xx. Fixed a bug that caused core dumps when expanding the value of HISTIGNORE.
8300
8301 yy. The output of `set' is now quoted using $'...' so invisible characters are
8302 displayed as escape sequences.
8303
8304 zz. Fixed the help text for `unset', since PATH and IFS may both be unset.
8305
8306 aaa. The shell no longer puts directory names into the command hash table.
8307
8308 bbb. Fixed a bug in `read' that caused it to occasionally free memory twice if
8309 it was interrupted after reading a large amount of data.
8310
8311 ccc. Assignment statements that attempt to assign values to readonly variables
8312 now cause the command to return an error status.
8313
8314 ddd. Fixed a bug that could cause incorrect output if a $(<file) construct was
8315 interrupted.
8316
8317 eee. GROUPS and FUNCNAME now return an error status when assignment is
8318 attempted, but may be unset (in which case they lose their special
8319 properties). In all respects except unsetting, they are readonly.
8320
8321 fff. The string-to-integer conversion code now ignores trailing whitespace in
8322 the string, even if strtol(3) does not.
8323
8324 ggg. The tcsh magic-space function now does a better job of inserting the
8325 space close to where the point was before the history expansion, rather
8326 than just appending it.
8327
8328 hhh. Fixed a bug which caused a file sourced from an interactive shell to
8329 fill up the jobs table if it ran lots of jobs.
8330
8331 iii. Fixed a bug in the parameter pattern substitution code to avoid infinite
8332 recursion on zero-length matches.
8333
8334 2. Changes to Readline
8335
8336 a. When setting the terminal attributes on systems using `struct termio',
8337 readline waits for output to drain before changing the attributes.
8338
8339 b. A fix was made to the history word tokenization code to avoid attempts to
8340 dereference a null pointer.
8341
8342 c. Readline now defaults rl_terminal_name to $TERM if the calling application
8343 has left it unset, and tries to initialize with the resultant value.
8344
8345 d. Instead of calling (*rl_getc_function)() directly to get input in certain
8346 places, readline now calls rl_read_key() consistently.
8347
8348 e. Fixed a bug in the completion code that allowed a backslash to quote a
8349 single quote inside a single-quoted string.
8350
8351 f. rl_prompt is no longer assigned directly from the argument to readline(),
8352 but uses memory allocated by readline. This allows constant strings to
8353 be passed to readline without problems arising when the prompt processing
8354 code wants to modify the string.
8355
8356 g. Fixed a bug that caused non-interactive history searches to return the
8357 wrong line when performing multiple searches backward for the same string.
8358
8359 h. Many variables, function arguments, and function return values are now
8360 declared `const' where appropriate, to improve behavior when linking with
8361 C++ code.
8362
8363 i. The control character detection code now works better on systems where
8364 `char' is unsigned by default.
8365
8366 j. The vi-mode numeric argument is now capped at 999999, just like emacs mode.
8367
8368 k. The Function, CPFunction, CPPFunction, and VFunction typedefs have been
8369 replaced with a set of specific prototyped typedefs, though they are
8370 still in the readline header files for backwards compatibility.
8371
8372 m. Nearly all of the (undocumented) internal global variables in the library
8373 now have an _rl_ prefix -- there were a number that did not, like
8374 screenheight, screenwidth, alphabetic, etc.
8375
8376 n. The ding() convenience function has been renamed to rl_ding(), though the
8377 old function is still defined for backwards compatibility.
8378
8379 o. The completion convenience functions filename_completion_function,
8380 username_completion_function, and completion_matches now have an rl_
8381 prefix, though the old names are still defined for backwards compatibility.
8382
8383 p. The functions shared by readline and bash (linkage is satisfied from bash
8384 when compiling with bash, and internally otherwise) now have an sh_ prefix.
8385
8386 q. Changed the shared library creation procedure on Linux and BSD/OS 4.x so
8387 that the `soname' contains only the major version number rather than the
8388 major and minor numbers.
8389
8390 r. Fixed a redisplay bug that occurred when the prompt spanned more than one
8391 physical line and contained invisible characters.
8392
8393 3. New Features in Bash
8394
8395 a. Added a new `--init-file' invocation argument as a synonym for `--rcfile',
8396 per the new GNU coding standards.
8397
8398 b. The /dev/tcp and /dev/udp redirections now accept service names as well as
8399 port numbers.
8400
8401 c. `complete' and `compgen' now take a `-o value' option, which controls some
8402 of the aspects of that compspec. Valid values are:
8403
8404 default - perform bash default completion if programmable
8405 completion produces no matches
8406 dirnames - perform directory name completion if programmable
8407 completion produces no matches
8408 filenames - tell readline that the compspec produces filenames,
8409 so it can do things like append slashes to
8410 directory names and suppress trailing spaces
8411
8412 4. New Features in Readline
8413
8414 a. The blink timeout for paren matching is now settable by applications.
8415
8416 b. _rl_executing_macro has been renamed to rl_executing_macro, which means
8417 it's now part of the public interface.
8418
8419 c. Readline has a new variable, rl_readline_state, which is a bitmap that
8420 encapsulates the current state of the library; intended for use by
8421 callbacks and hook functions.
8422
8423 ------------------------------------------------------------------------------
8424 This document details the changes between this version, bash-2.04-release,
8425 and the previous version, bash-2.04-beta5.
8426
8427 1. Changes to Bash
8428
8429 a. Better compile-time and configure-time checks for the necessity of
8430 inet_aton().
8431
8432 b. A bug was fixed in the expansion of "${@:-}" when there are positional
8433 parameters.
8434
8435 c. A typo was fixed in the output of `complete'.
8436
8437 d. The matches generated for a word by the `-W' argument to complete and
8438 compgen are now matched against the word being completed, and only
8439 matches are returned as the result.
8440
8441 e. Some fixes were made for systems which do not restart read(2) when a
8442 signal caught by bash is received.
8443
8444 f. A bug was fixed which caused the umask to be set to 0 when an invalid
8445 symbolic mode mask was parsed.
8446
8447 g. Fixed a bug that could cause a core dump if a SIGCHLD was received while
8448 performing an assignment statement using command substitution.
8449
8450 h. Changed the word splitting function for programmable completion so cases
8451 in which the cursor is between words are handled a bit better.
8452
8453 2. Changes to Readline
8454
8455 a. rl_funmap_names() is now documented.
8456
8457 3. New Features in Bash
8458
8459 a. The LC_NUMERIC variable is now treated specially, and used to set the
8460 LC_NUMERIC locale category for number formatting, e.g., when `printf'
8461 displays floating-point numbers.
8462
8463 ------------------------------------------------------------------------------
8464 This document details the changes between this version, bash-2.04-beta5,
8465 and the previous version, bash-2.04-beta4.
8466
8467 1. Changes to Bash
8468
8469 a. A couple of changes were made to the Makefiles for easier building on
8470 non-Unix systems.
8471
8472 b. Fixed a bug where the current prompt would be set to $PS2 at startup.
8473
8474 c. The shell script that tests an already-installed version was changed to
8475 remove the directory it created its test programs in at exit.
8476
8477 d. Several changes were made to the code that tokenizes an input line for
8478 the programmable completion code. Shell metacharacters will now appear
8479 as individual words in the word list passed to the completion functions.
8480 Some of the example completion shell functions were changed to understand
8481 redirection operators.
8482
8483 e. A bug was fixed that, under obscure circumstances, could confuse the
8484 parser when a shell function was run by the programmable completion code.
8485
8486 f. A bug was fixed in the ulimit builtin for systems not using getrlimit().
8487
8488 g. The execution code now propagates the correct exit status back to the rest
8489 of the code if the return value of a subshell command was being inverted.
8490 Some new test cases for inverting return values with the `!' reserved
8491 word have been added.
8492
8493 h. Negative exponents in the arithmetic evaluation of v**e now return an
8494 evaluation error.
8495
8496 i. A bug that caused bash to check the wrong process in a pipeline for
8497 abnormal termination (and consequently resetting the terminal attributes)
8498 was fixed.
8499
8500 j. Fixed a bug that caused $PS2 to be displayed after PROMPT_COMMAND was
8501 executed.
8502
8503 2. Changes to Readline
8504
8505 1. Fixed a bug in a C preprocessor define that caused the keypad control
8506 functions to be compiled out for all platforms except DJGPP.
8507
8508 ------------------------------------------------------------------------------
8509 This document details the changes between this version, bash-2.04-beta4,
8510 and the previous version, bash-2.04-beta3.
8511
8512 1. Changes to Bash
8513
8514 a. A couple of changes were made to the redirection to attempt to avoid
8515 race conditions and malicious file replacement.
8516
8517 2. A change was made to the string evaluation code (used for command
8518 substitution, `eval', and the `.' builtin) to fix an obscure core
8519 dump on alpha machines.
8520
8521 3. A bug that caused $LINENO to be wrong when executing arithmetic for
8522 commands was fixed.
8523
8524 4. A couple of memory leaks in the programmable completion code were fixed.
8525
8526 5. A bug that could cause a core dump by freeing memory twice during a call
8527 to `eval' if `set -u' had been enabled and an undefined variable was
8528 referenced was fixed.
8529
8530 ------------------------------------------------------------------------------
8531 This document details the changes between this version, bash-2.04-beta3,
8532 and the previous version, bash-2.04-beta2.
8533
8534 1. Changes to Bash
8535
8536 a. Bash should run the appropriate startup files when invoked by ssh2.
8537
8538 b. Fixed a bug in the parsing of conditional commands that could cause a
8539 core dump.
8540
8541 c. Fixed a bug in parsing job specifications that occasionally caused
8542 core dumps when an out-of-range job was referenced.
8543
8544 d. Fixed the `type' and `command' builtins to do better reporting of
8545 commands that are not found in $PATH or the hash table.
8546
8547 e. Fixed a POSIX.2 compliance problem in the command builtin -- commands
8548 are supposed to be reported as full pathnames.
8549
8550 f. The `echo' builtin now returns failure if a write error occurs.
8551
8552 g. Fixed a bug which caused the locale to not be reset correctly when
8553 LC_ALL was unset.
8554
8555 h. Changed description of `getopts' in man page and reference manual to make
8556 it clear that option characters may be characters other than letters.
8557
8558 i. If the shell exits while in a function, make sure that any trap on EXIT
8559 doesn't think the function is still executing.
8560
8561 j. Bashbug now tries harder to find a usable editor if $EDITOR is not set,
8562 rather than simply defaulting to `emacs'.
8563
8564 k. Changes to the scripts that guess and canonicalize the system type, from
8565 the latest `automake' distribution via Debian.
8566
8567 l. When using named pipes for process substitution, make sure the file
8568 descriptors opened for reading are set to non-blocking mode.
8569
8570 m. Fixed a bug that caused termination of pipelines that are killed by a
8571 signal to not be reported in some cases.
8572
8573 n. When not in literal-history mode, shell comment lines are not added to
8574 the history list.
8575
8576 o. When running in POSIX.2 mode, bash no longer performs word splitting on
8577 the expanded value of the word supplied as the filename argument to
8578 redirection operators.
8579
8580 p. The prompt string decoding code now backslash-quotes only characters that
8581 are special within double quotes when expanding the \w and \W escape
8582 sequences.
8583
8584 q. Fixed a bug in the prompt decoding code that could cause a non-interactive
8585 shell to seg fault if `\u' was used in PS4 and the shell was in xtrace
8586 mode.
8587
8588 r. Fixed a bug that caused function definitions to be printed with any
8589 redirections that should be attached to the entire function before the
8590 closing brace.
8591
8592 s. Changed the tilde expansion code for Cygwin systems to avoid creating
8593 pathnames beginning with `//' if $HOME == `/'.
8594
8595 t. Fixed a couple of autoconf tests to avoid creating files with fixed names
8596 in /tmp.
8597
8598 u. The `trap' and `kill' builtins now know the names of the POSIX.1b real-
8599 time signals on systems which support them.
8600
8601 2. Changes to Readline
8602
8603 a. Fixed a problem with the single-quote quoting function that could cause
8604 buffer overflows.
8605
8606 b. Fixed a bug that caused incorrect `stat characters' to be printed if
8607 the files being completed were in the root directory and visible-stats
8608 was enabled.
8609
8610 3. New Features in Bash
8611
8612 a. There is a new `rbash.1' manual page, from the Debian release.
8613
8614 b. The `--enable-usg-echo-default' option to `configure' has been renamed to
8615 `--enable-xpg-echo-default'. The old option is still there for backwards
8616 compatibility.
8617
8618 ------------------------------------------------------------------------------
8619 This document details the changes between this version, bash-2.04-beta2,
8620 and the previous version, bash-2.04-beta1.
8621
8622 1. Changes to Bash
8623
8624 a. Fixed a bug that could cause pipes to be closed inappropriately in
8625 some obscure cases.
8626
8627 b. Fixed a bug that caused creation of the exported environment to clobber
8628 the current command string if there were any exported shell functions.
8629
8630 c. Some changes were made to reduce bash's memory usage.
8631
8632 d. Fixed a problem with programmable completion and filenames to be
8633 completed containing quote characters.
8634
8635 e. Changed the code the removes named pipes created for the <(...) and >(...)
8636 expansions to defer removal until after any current shell function has
8637 finished executing.
8638
8639 f. Fixed a bug in `select' which caused it to not handle the `continue'
8640 builtin correctly.
8641
8642 g. Autoconf tests added for cygwin32 and mingw32.
8643
8644 2. New Features in Bash
8645
8646 a. The `--with-bash-malloc' configure option replaces `--with-gnu-malloc'
8647 (which is still there for backwards compatibility).
8648
8649 ------------------------------------------------------------------------------
8650 This document details the changes between this version, bash-2.04-beta1,
8651 and the previous version, bash-2.04-alpha1.
8652
8653 1. Changes to Bash
8654
8655 a. Fixed a bug in the programmable completion code that occurred when
8656 trying to complete command lines containing a `;' or `@'.
8657
8658 b. The file descriptor from which the shell is reading a script is now
8659 moved to a file descriptor above the user-addressible range.
8660
8661 c. Changes to `printf' so that it can handle integers beginning with 0
8662 or 0x as octal and hex, respectively.
8663
8664 d. Fixes to the programmable completion code so it handles nonsense like
8665 `compgen -C xyz' gracefully.
8666
8667 e. The shell no longer modifies the signal handler for SIGPROF, allowing
8668 profiling again on certain systems.
8669
8670 f. The shell checks for a new window size, if the user has requested it,
8671 after a process exits due to a signal.
8672
8673 g. Fixed a bug with variables with null values in a program's temporary
8674 environment and the bash getenv() replacement.
8675
8676 h. `declare' and the other builtins that take variable assignments as
8677 arguments now honor `set -a' and mark modified variables for export.
8678
8679 i. Some changes were made for --dump-po-strings mode when writing strings
8680 with embedded newlines.
8681
8682 j. The code that caches export strings from the initial environment now
8683 duplicates the string rather than just pointing into the environment.
8684
8685 k. The filename completion quoting code now uses single quotes by default
8686 if the filename being completed contains newlines, since \<newline>
8687 has a special meaning to the parser.
8688
8689 l. Bash now uses typedefs bits32_t and u_bits32_t instead of int32_t and
8690 u_int32_t, respectively to avoid conflicts on certain Unix versions.
8691
8692 m. Configuration changes were made for: Rhapsody, Mac OS, FreeBSD-3.x.
8693
8694 n. Fixed a problem with hostname-to-ip-address translation in the
8695 /dev/(tcp|udp)/hostname/port redirection code.
8696
8697 o. The texinfo manual has been reorganized slightly.
8698
8699 p. Filename generation (globbing) range comparisons in bracket expressions
8700 no longer use strcoll(3) even if it is available, since it has unwanted
8701 effects in certain locales.
8702
8703 q. Fixed a cosmetic problem in the source that caused the shell to not
8704 compile if DPAREN_ARITHMETIC was not defined but ARITH_FOR_COMMAND was.
8705
8706 r. Fixed a bug in the here-document code tripped when the file descriptor
8707 opened to the file containing the text of the here document was the
8708 same as a redirector specified by the user.
8709
8710 s. Fixed a bug where the INVERT_RETURN flag was not being set for `pipeline'
8711 in `time ! pipeline'.
8712
8713 t. Fixed a bug with the `wait' builtin which manifested itself when an
8714 interrupt was received while the shell was waiting for asynchronous
8715 processes in a shell script.
8716
8717 u. Fixed the DEBUG trap code so that it has the correct value of $?.
8718
8719 v. Fixed a bug in the parameter pattern substitution code that could cause
8720 the shell to attempt to free unallocated memory if the pattern started
8721 with `/' and an expansion error occurs.
8722
8723 w. Fixed a bug in the positional parameter substring code that could
8724 cause the shell to loop freeing freed memory.
8725
8726 x. Fixed a bug in the positional parameter pattern substitution code so
8727 that it correctly handles null replacement strings with a pattern
8728 string prefixed with `%' or `#'.
8729
8730 y. The shell no longer attempts to import functions from the environment if
8731 started with `-n'.
8732
8733 z. Fixed a bug that caused `return' in a command substitution executed in
8734 a shell function to return from the function in a subshell and continue
8735 execution.
8736
8737 aa. `hash -p /pathname/with/slashes name' is no longer allowed when the shell
8738 is restricted.
8739
8740 bb. The wait* job control functions now behave better if called when there
8741 are no unwaited-for children.
8742
8743 cc. Command substitution no longer unconditionally disables job control in
8744 the subshell started to run the command.
8745
8746 dd. A bug was fixed that occasionally caused traps to mess up the parser
8747 state.
8748
8749 ee. `bashbug' now honors user headers in the mail message it sends.
8750
8751 ff. A bug was fixed that caused the `:p' history modifier to not print the
8752 history expansion if the `histverify' option was set.
8753
8754 2. Changes to Readline
8755
8756 a. Fixed a bug in the redisplay code for lines with more than 256 line
8757 breaks.
8758
8759 b. A bug was fixed which caused invisible character markers to not be
8760 stripped from the prompt string if the terminal was in no-echo mode.
8761
8762 c. Readline no longer tries to get the variables it needs for redisplay
8763 from the termcap entry if the calling application has specified its
8764 own redisplay function. Readline treats the terminal as `dumb' in
8765 this case.
8766
8767 d. Fixes to the SIGWINCH code so that a multiple-line prompt with escape
8768 sequences is redrawn correctly.
8769
8770 3. New Features in Bash
8771
8772 a. `bashbug' now accepts `--help' and `--version' options.
8773
8774 b. There is a new `xpg_echo' option to `shopt' that controls the behavior
8775 of echo with respect to backslash-escaped characters at runtime.
8776
8777 ------------------------------------------------------------------------------
8778 This document details the changes between this version, bash-2.04-alpha1,
8779 and the previous version, bash-2.04-devel.
8780
8781 1. Changes to Bash
8782
8783 a. Fixed a bug that could cause core dumps when performing substring
8784 expansion.
8785
8786 b. Shared object configuration changes for: Solaris, OSF/1
8787
8788 c. The POSIX_GLOB_LIBRARY code that uses the POSIX.2 globbing facilities
8789 for pathname expansion now understands GLOBIGNORE.
8790
8791 d. The code that implements `eval' was changed to save the value of the
8792 current prompt, so an eval in a shell function called by the programmable
8793 completion code will not change the prompt to $PS2.
8794
8795 e. Restored the undocumented NON_INTERACTIVE_LOGIN_SHELLS #define to
8796 config-top.h. If this is defined, all login shells will read the
8797 startup files, not just interactive and non-interactive started with
8798 the `--login' option.
8799
8800 f. Fixed a bug that caused the expansion code to occasionally dump core if
8801 IFS contained characters > 128.
8802
8803 g. Fixed a problem with the grammar so that a newline is not required
8804 after the `))' in the new-style arithmetic for statement; a semicolon
8805 may be used as expected.
8806
8807 h. Variable indirection may now reference the shell's special variables.
8808
8809 i. The $'...' and $"..." constructs are now added to the history correctly
8810 if they contain newlines and command-oriented history is enabled.
8811
8812 j. It is now an error to try to assign a value to a function-local copy
8813 of a readonly shell variable (declared with the `local' builtin).
8814
8815 2. Changes to Readline
8816
8817 a. The history file code now uses O_BINARY mode when reading and writing
8818 the history file on cygwin32.
8819
8820 3. New Features in Bash
8821
8822 a. A new programmable completion facility, with two new builtin commands:
8823 complete and compgen.
8824
8825 b. configure has a new option, `--enable-progcomp', to compile in the
8826 programmable completion features (enabled by default).
8827
8828 c. `shopt' has a new option, `progcomp', to enable and disable programmable
8829 completion at runtime.
8830
8831 d. Unsetting HOSTFILE now clears the list of hostnames used for completion.
8832
8833 4. New Features in Readline
8834
8835 a. A new variable, rl_gnu_readline_p, always 1. The intent is that an
8836 application can verify whether or not it is linked with the `real'
8837 readline library or some substitute.
8838
8839 ------------------------------------------------------------------------------
8840 This document details the changes between this version, bash-2.04-devel,
8841 and the previous version, bash-2.03-release.
8842
8843 1. Changes to Bash
8844
8845 a. System-specific configuration and source changes for: Interix, Rhapsody
8846
8847 b. Fixed a bug in execute_cmd.c that resulted in a compile-time error if
8848 JOB_CONTROL was not defined.
8849
8850 c. An obscure race condition in the trap code was fixed.
8851
8852 d. The string resulting from $'...' is now requoted to avoid any further
8853 expansion.
8854
8855 e. The $'...' quoting syntax now allows backslash to escape a single quote,
8856 for ksh-93 compatibility.
8857
8858 f. The $"..." quoting syntax now escapes backslashes and double quotes in
8859 the translated string when displaying them with the --dump-po-strings
8860 option.
8861
8862 g. `echo -e' no longer converts \' to '.
8863
8864 h. Fixes were made to the extended globbing code to handle embedded (...)
8865 patterns better.
8866
8867 i. Some improvements were made to the code that unsets `nodelay' mode on
8868 the file descriptor from which bash is reading input.
8869
8870 j. Some changes were made to the replacement termcap library for better
8871 operation on MS-DOS.
8872
8873 k. Some changes were made to the tilde expansion code to handle backslash
8874 as a pathname separator on MS-DOS.
8875
8876 l. The source has been reorganized a little bit -- there is now an `include'
8877 subdirectory, and lib/posixheaders has been removed.
8878
8879 m. Improvements were made to the `read' builtin so that it makes many
8880 fewer read(2) system calls.
8881
8882 n. The expansion of $- will include `c' and `s' when those options are
8883 supplied at shell invocation.
8884
8885 o. Several improvements were made to the completion code: variable completion
8886 now works better when there are unterminated expansions, command
8887 completion understands quotes better, and completion now works in certain
8888 unclosed $(... constructs.
8889
8890 p. The arithmetic expansion code was fixed to not need the value of a
8891 variable being assigned a value (fixes the "ss=09; let ss=10" bug).
8892
8893 q. Some changes were made to make exported environment creation faster.
8894
8895 r. The html documentation will be installed into $(htmldir) if that variable
8896 has a value when `make install' is run.
8897
8898 s. Fixed a bug that would cause the bashrc file to be sourced inappropriately
8899 when bash is started by sshd.
8900
8901 t. The SSH_CLIENT environment variable is no longer auto-exported.
8902
8903 u. A bug that caused redirections with (...) subshells to be performed in
8904 the wrong order was fixed.
8905
8906 v. A bug that occasionally caused inappropriate expansion of assignment
8907 statements in compound array assignments was fixed.
8908
8909 w. The code that parses the words in a compound array assignment was
8910 simplified considerably and should work better now.
8911
8912 x. Fixes to the non-job-control code in nojobs.c to make it POSIX.2-compliant
8913 when a user attempts to retrieve the status of a terminated background
8914 process.
8915
8916 y. Fixes to the `printf' builtin so that it doesn't try to expand all
8917 backslash escape sequences in the format string before parsing it for
8918 % format specifiers.
8919
8920 2. Changes to Readline
8921
8922 a. The history library tries to truncate the history file only if it is a
8923 regular file.
8924
8925 b. A bug that caused _rl_dispatch to address negative array indices on
8926 systems with signed chars was fixed.
8927
8928 c. rl-yank-nth-arg now leaves the history position the same as when it was
8929 called.
8930
8931 d. Changes to the completion code to handle MS-DOS drive-letter:pathname
8932 filenames.
8933
8934 e. Completion is now case-insensitive by default on MS-DOS.
8935
8936 f. Fixes to the history file manipulation code for MS-DOS.
8937
8938 g. Readline attempts to bind the arrow keys to appropriate defaults on MS-DOS.
8939
8940 h. Some fixes were made to the redisplay code for better operation on MS-DOS.
8941
8942 i. The quoted-insert code will now insert tty special chars like ^C.
8943
8944 j. A bug was fixed that caused the display code to reference memory before
8945 the start of the prompt string.
8946
8947 k. More support for __EMX__ (OS/2).
8948
8949 l. A bug was fixed in readline's signal handling that could cause infinite
8950 recursion in signal handlers.
8951
8952 m. A bug was fixed that caused the point to be less than zero when rl_forward
8953 was given a very large numeric argument.
8954
8955 n. The vi-mode code now gets characters via the application-settable value
8956 of rl_getc_function rather than calling rl_getc directly.
8957
8958 3. New Features in Bash
8959
8960 a. The history builtin has a `-d offset' option to delete the history entry
8961 at position `offset'.
8962
8963 b. The prompt expansion code has two new escape sequences: \j, the number of
8964 active jobs; and \l, the basename of the shell's tty device name.
8965
8966 c. The `bind' builtin has a new `-x' option to bind key sequences to shell
8967 commands.
8968
8969 d. There is a new shell option, no_empty_command_completion, which, when
8970 enabled, disables command completion when TAB is typed on an empty line.
8971
8972 e. The `help' builtin has a `-s' option to just print a builtin's usage
8973 synopsis.
8974
8975 f. There are several new arithmetic operators: id++, id-- (variable
8976 post-increment/decrement), ++id, --id (variabl pre-increment/decrement),
8977 expr1 , expr2 (comma operator).
8978
8979 g. There is a new ksh-93 style arithmetic for command:
8980 for ((expr1 ; expr2; expr3 )); do list; done
8981
8982 h. The `read' builtin has a number of new options:
8983 -t timeout only wait timeout seconds for input
8984 -n nchars only read nchars from input instead of a full line
8985 -d delim read until delim rather than newline
8986 -s don't echo input chars as they are read
8987
8988 i. The redirection code now handles several filenames specially:
8989 /dev/fd/N, /dev/stdin, /dev/stdout, and /dev/stderr, whether or
8990 not they are present in the file system.
8991
8992 j. The redirection code now recognizes pathnames of the form
8993 /dev/tcp/host/port and /dev/udp/host/port, and tries to open a socket
8994 of the appropriate type to the specified port on the specified host.
8995
8996 k. The ksh-93 ${!prefix*} expansion, which expands to the names of all
8997 shell variables whose names start with prefix, has been implemented.
8998
8999 l. There is a new dynamic variable, FUNCNAME, which expands to the name of
9000 a currently-executing function. Assignments to FUNCNAME have no effect.
9001
9002 m. The GROUPS variable is no longer readonly; assignments to it are silently
9003 discarded. This means it can be unset.
9004
9005 4. New Features in Readline
9006
9007 a. Parentheses matching is now always compiled into readline, and enabled
9008 or disabled when the value of the `blink-matching-paren' variable is
9009 changed.
9010
9011 b. MS-DOS systems now use ~/_inputrc as the last-ditch inputrc filename.
9012
9013 c. MS-DOS systems now use ~/_history as the default history file.
9014
9015 d. history-search-{forward,backward} now leave the point at the end of the
9016 line when the string to search for is empty, like
9017 {reverse,forward}-search-history.
9018
9019 e. history-search-{forward,backward} now leave the last history line found
9020 in the readline buffer if the second or subsequent search fails.
9021
9022 f. New function for use by applications: rl_on_new_line_with_prompt, used
9023 when an application displays the prompt itself before calling readline().
9024
9025 g. New variable for use by applications: rl_already_prompted. An application
9026 that displays the prompt itself before calling readline() must set this to
9027 a non-zero value.
9028
9029 ------------------------------------------------------------------------------
9030 This document details the changes between this version, bash-2.03-release,
9031 and the previous version, bash-2.03-beta2.
9032
9033 1. Changes to Bash
9034
9035 a. A file descriptor leak in the `fc' builtin was fixed.
9036
9037 b. A bug was fixed in the `read' builtin that caused occasional spurious
9038 failures when using `read -e'.
9039
9040 c. The version code needed to use the value of the cpp variable
9041 CONF_MACHTYPE rather than MACHTYPE.
9042
9043 d. A new test was added to exercise the command printing and copying code.
9044
9045 e. A bug was fixed that caused `time' to be recognized as a reserved word
9046 if it was the first pattern in a `case' statement pattern list.
9047
9048 ------------------------------------------------------------------------------
9049 This document details the changes between this version, bash-2.03-beta2,
9050 and the previous version, bash-2.03-beta1.
9051
9052 1. Changes to Bash
9053
9054 a. Slight additions to support/shobj-conf, mostly for the benefit of AIX 4.2.
9055
9056 b. config.{guess,sub} support added for the NEC SX4.
9057
9058 c. Changed some of the cross-compiling sections of the configure macros in
9059 aclocal.m4 so that configure won't abort.
9060
9061 d. Slight changes to how the HTML versions of the bash and readline manuals
9062 are generated.
9063
9064 e. Fixed conditional command printing to avoid interpreting printf `%'-escapes
9065 in arguments to [[.
9066
9067 f. Don't include the bash malloc on all variants of the alpha processor.
9068
9069 g. Changes to configure to make --enable-profiling work on Solaris 2.x.
9070
9071 h. Fixed a bug that manifested itself when shell functions were called
9072 between calls to `getopts'.
9073
9074 i. Fixed pattern substitution so that a bare `#'as a pattern causes the
9075 replacement string to be prefixed to the search string, and a bare
9076 `%' causes the replacement string to be appended to the search string.
9077
9078 j. Fixed a bug in the command execution code that caused child processes
9079 to occasionally have the wrong value for $!.
9080
9081 2. Changes to Readline
9082
9083 a. Added code to the history library to catch history substitutions using
9084 `&' without a previous history substitution or search having been
9085 performed.
9086
9087 3. New Features in Bash
9088
9089 4. New Features in Readline
9090
9091 a. New bindable variable: `isearch-terminators'.
9092
9093 b. New bindable function: `forward-backward-delete-char' (unbound by default).
9094
9095 ------------------------------------------------------------------------------
9096 This document details the changes between this version, bash-2.03-beta1,
9097 and the previous version, bash-2.03-alpha.
9098
9099 1. Changes to Bash
9100
9101 a. A change was made to the help text for `{...}' to make it clear that a
9102 semicolon is required before the closing brace.
9103
9104 b. A fix was made to the `test' builtin so that syntax errors cause test
9105 to return an exit status > 1.
9106
9107 c. Globbing is no longer performed on assignment statements that appear as
9108 arguments to `assignment builtins' such as `export'.
9109
9110 d. System-specific configuration changes were made for: Rhapsody,
9111 AIX 4.2/gcc, BSD/OS 4.0.
9112
9113 e. New loadable builtins: ln, unlink.
9114
9115 f. Some fixes were made to the globbing code to handle extended glob patterns
9116 which immediately follow a `*'.
9117
9118 g. A fix was made to the command printing code to ensure that redirections
9119 following compound commands have a space separating them from the rest
9120 of the command.
9121
9122 h. The pathname canonicalization code was changed to produce fewer leading
9123 `//' sequences, since those are interpreted as network file system
9124 pathnames on some systems.
9125
9126 i. A fix was made so that loops containing `eval' commands in commands passed
9127 to `bash -c' would not exit prematurely.
9128
9129 j. Some changes were made to the job reaping code when the shell is not
9130 interactive, so the shell will retain exit statuses longer for examination
9131 by `wait'.
9132
9133 k. A fix was made so that `jobs | command' works again.
9134
9135 l. The erroneous compound array assignment var=((...)) is now a syntax error.
9136
9137 m. A change was made to the dynamic loading code in `enable' to support
9138 Tenon's MachTen.
9139
9140 n. A fix was made to the globbing code so that extended globbing patterns
9141 will correctly match `.' in a bracket expression.
9142
9143 2. Changes to Readline
9144
9145 a. A fix was made to the completion code in which a typo caused the wrong
9146 value to be passed to the function that computed the longest common
9147 prefix of the list of matches.
9148
9149 b. The completion code now checks the value of rl_filename_completion_desired,
9150 which is set by application-supplied completion functions to indicate
9151 that filename completion is being performed, to decide whether or not to
9152 call an application-supplied `ignore completions' function.
9153
9154 3. New Features in Bash
9155
9156 a. A change was made to the startup file code so that any shell begun with
9157 the `--login' option, even non-interactive shells, will source the login
9158 shell startup files.
9159
9160 4. New Features in Readline
9161
9162 a. A new variable, rl_erase_empty_line, which, if set by an application using
9163 readline, will cause readline to erase, prompt and all, lines on which the
9164 only thing typed was a newline.
9165
9166 ------------------------------------------------------------------------------
9167 This document details the changes between this version, bash-2.03-alpha,
9168 and the previous version, bash-2.02.1-release.
9169
9170 1. Changes to Bash
9171
9172 a. System-specific configuration changes were made for: Irix 6.x, Unixware 7.
9173
9174 b. The texi2dvi and texi2html scripts were updated to the latest versions
9175 from the net.
9176
9177 c. The configure tests that determine which native type is 32 bits were
9178 changed to not require a compiled program.
9179
9180 d. Fixed a bug in shell_execve that could cause memory to be freed twice
9181 after a failed exec.
9182
9183 e. The `printf' test uses `diff -a' if it's available to prevent confusion
9184 due to the non-ascii output.
9185
9186 f. Shared object configuration is now performed by a shell script,
9187 support/shobj-conf, which generates values to be substituted into
9188 makefiles by configure.
9189
9190 g. Some changes were made to `ulimit' to avoid the use of RLIM_INVALID as a
9191 return value.
9192
9193 h. Changes were made to `ulimit' to work around HPUX 9.x's peculiar
9194 handling of RLIMIT_FILESIZE.
9195
9196 i. Some new loadable builtins were added: id, printenv, sync, whoami, push,
9197 mkdir. `pushd', `popd', and `dirs' can now be built as regular or
9198 loadable builtins from the same source file.
9199
9200 j. Changes were made to `printf' to handle NUL bytes in the expanded format
9201 string.
9202
9203 k. The various `make clean' Makefile targets now descend into lib/sh.
9204
9205 l. The `type' builtin was changed to use the internal `getopt' so that things
9206 like `type -ap' work as expected.
9207
9208 m. There is a new configuration option, --with-installed-readline, to link
9209 bash with a locally-installed version of readline. Only readline version
9210 4.0 and later releases can support this. Shared and static libraries
9211 are supported. The installed include files are used.
9212
9213 n. There is a new autoconf macro used to find which basic type is 64 bits.
9214
9215 o. Dynamic linking and loadable builtins should now work on SCO 3.2v5*,
9216 AIX 4.2 with gcc, Unixware 7, and many other systems using gcc, where
9217 the `-shared' options works correctly.
9218
9219 p. A bug was fixed in the bash filename completion code that caused memory to
9220 be freed twice if a directory name containing an unset variable was
9221 completed and the -u option was set.
9222
9223 q. The prompt expansion code now quotes the `$' in the `\$' expansion so it
9224 is not processed by subsequent parameter expansion.
9225
9226 r. Fixed a parsing bug that caused a single or double quote after a `$$' to
9227 trigger ANSI C expansion or locale translation.
9228
9229 s. Fixed a bug in the globbing code that caused quoted filenames containing
9230 no globbing characters to sometimes be incorrectly expanded.
9231
9232 t. Changes to the default prompt strings if prompt string decoding is not
9233 compiled into the shell.
9234
9235 u. Added `do', `then', `else', `{', and `(' to the list of keywords that may
9236 precede the `time' reserved word.
9237
9238 v. The shell may now be cross-built for BeOS as well as cygwin32.
9239
9240 w. The conditional command execution code now treats `=' the same as `=='
9241 for deciding when to perform pattern matching.
9242
9243 x. The `-e' option no longer causes the shell to exit if a command exits
9244 with a non-zero status while running the startup files.
9245
9246 y. The `printf' builtin no longer dumps core if a modifier is supplied in
9247 the format string without a conversion character (e.g. `%h').
9248
9249 z. Array assignments of the form a=(...) no longer show up in the history
9250 list.
9251
9252 aa. The parser was fixed to obey the POSIX.2 rules for finding the closing
9253 `}' in a ${...} expression.
9254
9255 bb. The history file is now opened with mode 0600 rather than 0666, so bash
9256 no longer relies on the user's umask being set appropriately.
9257
9258 cc. Setting LANG no longer causes LC_ALL to be assigned a value; bash now
9259 relies on proper behavior from the C library.
9260
9261 dd. Minor changes were made to allow quoted variable expansions using
9262 ${...} to be completed correctly if there is no closing `"'.
9263
9264 ee. Changes were made to builtins/Makefile.in so that configuring the shell
9265 with `--enable-profiling' works right and builtins/mkbuiltins is
9266 generated.
9267
9268 2. Changes to Readline
9269
9270 a. The version number is now 4.0.
9271
9272 b. There is no longer any #ifdef SHELL code in the source files.
9273
9274 c. Some changes were made to the key binding code to fix memory leaks and
9275 better support Win32 systems.
9276
9277 d. Fixed a silly typo in the paren matching code -- it's microseconds, not
9278 milliseconds.
9279
9280 e. The readline library should be compilable by C++ compilers.
9281
9282 f. The readline.h public header file now includes function prototypes for
9283 all readline functions, and some changes were made to fix errors in the
9284 source files uncovered by the use of prototypes.
9285
9286 g. The maximum numeric argument is now clamped at 1000000.
9287
9288 h. Fixes to rl_yank_last_arg to make it behave better.
9289
9290 i. Fixed a bug in the display code that caused core dumps if the prompt
9291 string length exceeded 1024 characters.
9292
9293 j. The menu completion code was fixed to properly insert a single completion
9294 if there is only one match.
9295
9296 k. A bug was fixed that caused the display code to improperly display tabs
9297 after newlines.
9298
9299 3. New Features in Bash
9300
9301 a. New `shopt' option, `restricted_shell', indicating whether or not the
9302 shell was started in restricted mode, for use in startup files.
9303
9304 b. Filename generation is now performed on the words between ( and ) in
9305 array assignments (which it probably should have done all along).
9306
9307 c. OLDPWD is now auto-exported, as POSIX.2 seems to require.
9308
9309 d. ENV and BASH_ENV are read-only variables in a restricted shell.
9310
9311 4. New Features in Readline
9312
9313 a. Many changes to the signal handling:
9314 o Readline now catches SIGQUIT and cleans up the tty before returning;
9315 o A new variable, rl_catch_signals, is available to application writers
9316 to indicate to readline whether or not it should install its own
9317 signal handlers for SIGINT, SIGTERM, SIGQUIT, SIGALRM, SIGTSTP,
9318 SIGTTIN, and SIGTTOU;
9319 o A new variable, rl_catch_sigwinch, is available to application
9320 writers to indicate to readline whether or not it should install its
9321 own signal handler for SIGWINCH, which will chain to the calling
9322 applications's SIGWINCH handler, if one is installed;
9323 o There is a new function, rl_free_line_state, for application signal
9324 handlers to call to free up the state associated with the current
9325 line after receiving a signal;
9326 o There is a new function, rl_cleanup_after_signal, to clean up the
9327 display and terminal state after receiving a signal;
9328 o There is a new function, rl_reset_after_signal, to reinitialize the
9329 terminal and display state after an application signal handler
9330 returns and readline continues
9331
9332 b. There is a new function, rl_resize_terminal, to reset readline's idea of
9333 the screen size after a SIGWINCH.
9334
9335 c. New public functions: rl_save_prompt and rl_restore_prompt. These were
9336 previously private functions with a `_' prefix.
9337
9338 d. New function hook: rl_pre_input_hook, called just before readline starts
9339 reading input, after initialization.
9340
9341 e. New function hook: rl_display_matches_hook, called when readline would
9342 display the list of completion matches. The new function
9343 rl_display_match_list is what readline uses internally, and is available
9344 for use by application functions called via this hook.
9345
9346 f. New bindable function, delete-char-or-list, like tcsh.
9347
9348 ------------------------------------------------------------------------------
9349 This document details the changes between this version, bash-2.02.1-release,
9350 and the previous version, bash-2.02-release.
9351
9352 1. Changes to Bash
9353
9354 a. A bug that caused the bash readline support to not compile unless aliases
9355 and csh-style history were configured into the shell was fixed.
9356
9357 b. Fixed a bug that could cause a core dump when here documents contained
9358 more than 1000 characters.
9359
9360 c. Fixed a bug that caused a CDPATH entry of "" to not be treated the same
9361 as the current directory when in POSIX mode.
9362
9363 d. Fixed an alignment problem with the memory returned by the bash malloc,
9364 so returned memory is now 64-bit aligned.
9365
9366 e. Fixed a bug that caused command substitutions executed within pipelines
9367 to put the terminal in the wrong process group.
9368
9369 f. Fixes to support/config.sub for: alphas, SCO Open Server and Open Desktop,
9370 Unixware 2, and Unixware 7.
9371
9372 g. Fixes to the pattern matching code to make it work correctly for eight-bit
9373 characters.
9374
9375 h. Fixed a problem that occasionally caused the shell to display the wrong
9376 value for the new working directory when changing to a directory found
9377 in $CDPATH when in physical mode.
9378
9379 i. Fixed a bug that caused core dumps when using conditional commands in
9380 shell functions.
9381
9382 j. Fixed a bug that caused the printf builtin to loop forever if the format
9383 string did not consume any of the arguments.
9384
9385 k. Fixed a bug in the parameter expansion code that caused "$@" to be
9386 incorrectly split if $IFS did not contain a space character.
9387
9388 l. Fixed a bug that could cause a core dump when completing hostnames if
9389 the number of matching hostnames was an exact multiple of 16.
9390
9391 m. Fixed a bug that caused the shell to fork too early when a command
9392 such as `%2 &' was given.
9393
9394 2. Changes to Readline
9395
9396 a. Fixed a problem with redisplay that showed up when the prompt string was
9397 longer than the screen width and the prompt contained invisible characters.
9398
9399 ------------------------------------------------------------------------------
9400 This document details the changes between this version, bash-2.02-release,
9401 and the previous version, bash-2.02-beta2.
9402
9403 1. Changes to Bash
9404
9405 a. A bug was fixed that caused the terminal process group to be set
9406 incorrectly when performing command substitution of builtins in a
9407 pipeline.
9408
9409 ------------------------------------------------------------------------------
9410 This document details the changes between this version, bash-2.02-beta2,
9411 and the previous version, bash-2.02-beta1.
9412
9413 1. Changes to Bash
9414
9415 a. Attempting to `wait' for stopped jobs now generates a warning message.
9416
9417 b. Pipelines which exit due to SIGPIPE in non-interactive shells are now
9418 not reported if the shell is compiled -DDONT_REPORT_SIGPIPE.
9419
9420 c. Some changes were made to builtins/psize.sh and support/bashbug.sh to
9421 attempt to avoid some /tmp file races and surreptitious file
9422 substitutions.
9423
9424 d. Fixed a bug that caused the shell not to compile if configured with
9425 dparen arithmetic but without aliases.
9426
9427 e. Fixed a bug that caused the input stream to be switched when assigning
9428 empty arrays with `bash -c'.
9429
9430 f. A bug was fixed in the readline expansion glue code that caused bash to
9431 dump core when expanding lines with an unclosed single quote.
9432
9433 g. A fix was made to the `cd' builtin so that using a non-empty directory
9434 from $CDPATH results in an absolute pathname of the new current working
9435 directory to be displayed after the current directory is changed.
9436
9437 h. Fixed a bug in the variable assignment code that caused the shell to
9438 dump core when referencing an unset variable with `set -u' enabled in
9439 an assignment statement preceding a command.
9440
9441 i. Fixed a bug in the exit trap code that caused reserved words to not be
9442 recognized under certain circumstances.
9443
9444 j. Fixed a bug in the parameter pattern substitution code so that quote
9445 removal is performed.
9446
9447 k. The shell should now configure correctly on Apple Rhapsody systems.
9448
9449 l. The `kill' builtin now prints a usage message if it is not passed any
9450 arguments.
9451
9452 ------------------------------------------------------------------------------
9453 This document details the changes between this version, bash-2.02-beta1,
9454 and the previous version, bash-2.02-alpha1.
9455
9456 1. Changes to Bash
9457
9458 a. A few compilation bugs were fixed in the new extended globbing code.
9459
9460 b. Executing arithmetic commands now sets the command name to `((' so
9461 error messages look right.
9462
9463 c. Fixed some build problems with various configuration options.
9464
9465 d. The `printf' builtin now aborts immediately if an illegal format
9466 character is encountered.
9467
9468 e. The code that creates here-documents now behaves better if the file it's
9469 trying to create already exists for some reason.
9470
9471 f. Fixed a problem with the extended globbing code that made patterns like
9472 `x+*' expand incorrectly.
9473
9474 g. The prompt string expansion code no longer quotes tildes with backslashes.
9475
9476 h. The bash getcwd() implementation in lib/sh/getcwd.c now behaves better in
9477 the presence of lstat(2) failures.
9478
9479 i. Fixed a bug with strsub() that caused core dumps when executing `fc -s'.
9480
9481 j. The mail checking code now ensures that it has a valid default mailpath.
9482
9483 k. A bug was fixed that caused local variables to be unset inappropriately
9484 when sourcing a script from within another sourced script.
9485
9486 l. A bug was fixed in the history saving code so that functions are saved
9487 in the history list correctly if `cmdhist' is enabled, but `lithist'
9488 is not.
9489
9490 m. A bug was fixed that caused printf overflows when displaying error
9491 messages.
9492
9493 n. It should be easier to build the loadble builtins in examples/loadables,
9494 though some manual editing of the generated Makefile is still required.
9495
9496 o. The user's primary group is now always ${GROUPS[0]}.
9497
9498 p. Some updates were made to support/config.guess from the GNU master copy.
9499
9500 q. Some changes were made to the autoconf support for Solaris 2.6 large
9501 files.
9502
9503 r. The `command' builtins now does the right thing when confstr(3) cannot
9504 find a value for _CS_PATH.
9505
9506 s. Extended globbing expressions like `*.!(c)' are not history expanded if
9507 `extglob' is enabled.
9508
9509 t. Using the `-P' option to `cd' will force the value that is assigned to
9510 PWD to not contain any symbolic links.
9511
9512 2. Changes to Readline
9513
9514 a. The code that prints completion listings now behaves better if one or
9515 more of the filenames contains non-printable characters.
9516
9517 b. The time delay when showing matching parentheses is now 0.5 seconds.
9518
9519 ------------------------------------------------------------------------------
9520 This document details the changes between this version, bash-2.02-alpha1,
9521 and the previous version, bash-2.01.1-release.
9522
9523 1. Changes to Bash
9524
9525 a. OS-specific configuration changes for: BSD/OS 3.x, Minix 2.x,
9526 Solaris 2.6, SINIX SVR4.
9527
9528 b. Changes were made to the generated `info' files so that `install-info'
9529 works correctly.
9530
9531 c. PWD is now auto-exported.
9532
9533 d. A fix was made to the pipeline code to make sure that the shell forks
9534 to execute simple commands consisting solely of assignment statements.
9535
9536 e. Changes to the test suite for systems with 14-character filenames.
9537
9538 f. The default sizes of some internal hash tables have been made smaller
9539 to reduce the shell's memory footprint.
9540
9541 g. The `((...))' arithmetic command is now executed directly instead of
9542 being translated into `let "..."'.
9543
9544 h. Fixes were made to the expansion code so that "$*", "$@", "${array[@]}",
9545 and "${array[@]}" expand correctly when IFS does not contain a space
9546 character, is unset, or is set to NULL.
9547
9548 i. The indirect expansion code (${!var}) was changed so that the only
9549 valid values of `var' are variable names, positional parameters, `#',
9550 `@', and `*'.
9551
9552 j. An arithmetic expression error in a $((...)) expansion now causes a
9553 non-interactive shell running in posix mode to exit.
9554
9555 k. Compound array assignment now splits the words within the parentheses
9556 on shell metacharacters like the parser would before expansing them
9557 and performing the assignment. This is for compatibility with ksh-93.
9558
9559 l. The internal shell backslash-quoting code (used in the output of `set'
9560 and completion) now quotes tildes if they appear at the start of the
9561 string or after a `=' or `:'.
9562
9563 m. A couple of bugs with `shopt -o' were fixed.
9564
9565 n. `bash +o' now displays the same output as `set +o' before starting an
9566 interactive shell.
9567
9568 o. A bug that caused command substitution and the `eval' builtin to
9569 occasionally free memory twice when an error was encountered was fixed.
9570
9571 p. The filename globbing code no longer requires read permission for a
9572 directory when the filename to be matched does not contain any globbing
9573 characters, as POSIX.2 specifies.
9574
9575 q. A bug was fixed so that the job containing the last asynchronous
9576 process is not removed from the job table until a `wait' is executed
9577 for that process or another asynchronous process is started. This
9578 satisfies a POSIX.2 requirement.
9579
9580 r. A `select' bug was fixed so that a non-numeric user response is treated
9581 the same as a numeric response that is out of range.
9582
9583 s. The shell no longer parses the value of SHELLOPTS from the environment
9584 if it is restricted, running setuid, or running in `privileged mode'.
9585
9586 t. Fixes were made to enable large file support on systems such as
9587 Solaris 2.6, where the size of a file may be larger than can be held
9588 in an `int'.
9589
9590 u. The filename hashing code was fixed to not add `./' to the beginning of
9591 filenames which already begin with `./'.
9592
9593 v. The configure script was changed so that the GNU termcap library is not
9594 compiled in if `prefer-curses' has been specified.
9595
9596 w. HISTCONTROL and HISTIGNORE are no longer applied to the second and
9597 subsequent lines of a multi-line command.
9598
9599 x. A fix was made to `disown' so that it does a better job of catching
9600 out-of-range jobs.
9601
9602 y. Non-interactive shells no longer report the status of processes terminated
9603 due to SIGINT, even if the standard output is a terminal.
9604
9605 z. A bug that caused the output of `jobs' to have extra carriage returns
9606 was fixed.
9607
9608 aa. A bug that caused PIPESTATUS to not be set when builtins or shell
9609 functions were executed in the foreground was fixed.
9610
9611 bb. Bash now attempts to detect when it is being run by sshd, and treats
9612 that case identically to being run by rshd.
9613
9614 cc. A bug that caused `set -a' to export SHELLOPTS when one of the shell
9615 options was changed was fixed.
9616
9617 dd. The `kill' builtin now disallows empty or missing process id arguments
9618 instead of treating them as identical to `0', which means the current
9619 process.
9620
9621 ee. `var=value declare -x var' now behaves identically to
9622 `var=value export var'. Similarly for `var=value declare -r var' and
9623 `var=value readonly var'.
9624
9625 ff. A few memory leaks were fixed.
9626
9627 gg. `alias' and `unalias' now print error messages when passed an argument
9628 that is not an alias for printing or deletion, even when the shell is
9629 not interactive, as POSIX.2 specifies.
9630
9631 hh. `alias' and `alias -p' now return a status of 0 when no aliases are
9632 defined, as POSIX.2 specifies.
9633
9634 ii. `cd -' now prints the pathname of the new working directory if the shell
9635 is interactive.
9636
9637 jj. A fix was made so that the code that binds $PWD now copes with getcwd()
9638 returning NULL.
9639
9640 kk. `unset' now checks whether or not a function name it's trying to unset
9641 is a valid shell identifier only when the shell is running in posix mode.
9642
9643 ll. A change was made to the code that generates filenames for here documents
9644 to make them less prone to name collisions.
9645
9646 mm. The parser was changed so that `time' is recognized as a reserved word
9647 only at the beginning of a pipeline.
9648
9649 nn. The pathname canonicalization code was changed so that `//' is converted
9650 into `/', but all other pathnames beginning with `//' are left alone, as
9651 POSIX.2 specifies.
9652
9653 oo. The `logout' builtin will no longer exit a non-interactive non-login
9654 shell.
9655
9656 2. Changes to Readline
9657
9658 a. Fixed a problem in the readline test program rltest.c that caused a core
9659 dump.
9660
9661 b. The code that handles parser directives in inputrc files now displays
9662 more error messages.
9663
9664 c. The history expansion code was fixed so that the appearance of the
9665 history comment character at the beginning of a word inhibits history
9666 expansion for that word and the rest of the input line.
9667
9668 3. New Features in Bash
9669
9670 a. A new version of malloc, based on the older GNU malloc, that has many
9671 changes, is more page-based, is more conservative with memory usage,
9672 and does not `orphan' large blocks when they are freed.
9673
9674 b. A new version of gmalloc, based on the old GLIBC malloc, with many
9675 changes and range checking included by default.
9676
9677 c. A new implementation of fnmatch(3) that includes full POSIX.2 Basic
9678 Regular Expression matching, including character classes, collating
9679 symbols, equivalence classes, and support for case-insensitive pattern
9680 matching.
9681
9682 d. ksh-88 egrep-style extended pattern matching ([@+*?!](patlist)) has been
9683 implemented, controlled by a new `shopt' option, `extglob'.
9684
9685 e. There is a new ksh-like `[[' compound command, which implements
9686 extended `test' functionality.
9687
9688 f. There is a new `printf' builtin, implemented according to the POSIX.2
9689 specification.
9690
9691 g. There is a new feature for command substitution: $(< filename) now expands
9692 to the contents of `filename', with any trailing newlines removed
9693 (equivalent to $(cat filename)).
9694
9695 h. There are new tilde prefixes which expand to directories from the
9696 directory stack.
9697
9698 i. There is a new `**' arithmetic operator to do exponentiation.
9699
9700 j. There are new configuration options to control how bash is linked:
9701 `--enable-profiling', to allow bash to be profiled with gprof, and
9702 `--enable-static-link', to allow bash to be linked statically.
9703
9704 k. There is a new configuration option, `--enable-cond-command', which
9705 controls whether or not the `[[' command is included. It is on by
9706 default.
9707
9708 l. There is a new configuration option, `--enable-extended-glob', which
9709 controls whether or not the ksh extended globbing feature is included.
9710 It is enabled by default.
9711
9712 m. There is a new configuration #define in config.h.top that, when enabled,
9713 will cause all login shells to source /etc/profile and one of the user-
9714 specific login shell startup files, whether or not the shell is
9715 interactive.
9716
9717 n. There is a new invocation option, `--dump-po-strings', to dump
9718 a shell script's translatable strings ($"...") in GNU `po' format.
9719
9720 o. There is a new `shopt' option, `nocaseglob', to enable case-insensitive
9721 pattern matching when globbing filenames and using the `case' construct.
9722
9723 p. There is a new `shopt' option, `huponexit', which, when enabled, causes
9724 the shell to send SIGHUP to all jobs when an interactive login shell
9725 exits.
9726
9727 q. `bind' has a new `-u' option, which takes a readline function name as an
9728 argument and unbinds all key sequences bound to that function in a
9729 specified keymap.
9730
9731 r. `disown' now has `-a' and `-r' options, to limit operation to all jobs
9732 and running jobs, respectively.
9733
9734 s. The `shopt' `-p' option now causes output to be displayed in a reusable
9735 format.
9736
9737 t. `test' has a new `-N' option, which returns true if the filename argument
9738 has been modified since it was last accessed.
9739
9740 u. `umask' now has a `-p' option to print output in a reusable format.
9741
9742 v. A new escape sequence, `\xNNN', has been added to the `echo -e' and $'...'
9743 translation code. It expands to the character whose ascii code is NNN
9744 in hexadecimal.
9745
9746 w. The prompt string expansion code has a new `\r' escape sequence.
9747
9748 x. The shell may now be cross-compiled for the CYGWIN32 environment on
9749 a Unix machine.
9750
9751 4. New Features in Readline
9752
9753 a. There is now an option for `iterative' yank-last-arg handline, so a user
9754 can keep entering `M-.', yanking the last argument of successive history
9755 lines.
9756
9757 b. New variable, `print-completions-horizontally', which causes completion
9758 matches to be displayed across the screen (like `ls -x') rather than up
9759 and down the screen (like `ls').
9760
9761 c. New variable, `completion-ignore-case', which causes filename completion
9762 and matching to be performed case-insensitively.
9763
9764 d. There is a new bindable command, `magic-space', which causes history
9765 expansion to be performed on the current readline buffer and a space to
9766 be inserted into the result.
9767
9768 e. There is a new bindable command, `menu-complete', which enables tcsh-like
9769 menu completion (successive executions of menu-complete insert a single
9770 completion match, cycling through the list of possible completions).
9771
9772 f. There is a new bindable command, `paste-from-clipboard', for use on Win32
9773 systems, to insert the text from the Win32 clipboard into the editing
9774 buffer.
9775
9776 g. The key sequence translation code now understands printf-style backslash
9777 escape sequences, including \NNN octal escapes. These escape sequences
9778 may be used in key sequence definitions or macro values.
9779
9780 h. An `$include' inputrc file parser directive has been added.
9781
9782 ------------------------------------------------------------------------------
9783 This document details the changes between this version, bash-2.01.1-release,
9784 and the previous version, bash-2.01-release.
9785
9786 1. Changes to Bash
9787
9788 a. The select command was fixed to check the validity of the user's
9789 input more strenuously.
9790
9791 b. A bug was fixed that prevented `time' from timing commands correctly
9792 when supplied as an argument to `bash -c'.
9793
9794 c. A fix was made to the mail checking code to keep from adding the same
9795 mail file to the list of files to check multiple times when parsing
9796 $MAILPATH.
9797
9798 d. Fixed an off-by-one error in the tilde expansion library.
9799
9800 e. When using the compound array assignment syntax, the old value of
9801 the array is cleared before assigning the new value.
9802
9803 f. Fixed a bug that could cause a core dump when a trap handler was reset
9804 to the default in the trap command associated with that signal.
9805
9806 g. Fixed a bug in the locale code that occurred when assigning a value
9807 to LC_ALL.
9808
9809 h. A change was made to the parser so that words of the form xxx=(...)
9810 are not considered compound assignment statements unless there are
9811 characters before the `='.
9812
9813 i. A fix was made to the command tracing code to correctly quote each
9814 word of output.
9815
9816 j. Some changes were made to the bash-specific autoconf tests to make them
9817 more portable.
9818
9819 k. Completion of words with globbing characters now correctly quotes the
9820 result.
9821
9822 l. The directory /var/spool/mail is now preferred to /usr/spool/mail when
9823 configure is deciding on the default mail directory.
9824
9825 m. The brace completion code was fixed to not quote the `{' and `}'.
9826
9827 n. Some fixes were made to make $RANDOM more random in subshells.
9828
9829 o. System-specific changes were made to configure for: SVR4.2
9830
9831 p. Changes were made so that completion of words containing globbing chars
9832 substitutes the result only if a single filename was matched.
9833
9834 q. The window size is now recomputed after a job is stopped with SIGTSTP if
9835 the user has set `checkwinsize' with `shopt'.
9836
9837 r. When doing substring expansion, out-of-range substring specifiers now
9838 cause nothing to be substituted rather than an expansion error.
9839
9840 s. A fix was made so that you can no longer trap `SIGEXIT' or `SIGDEBUG' --
9841 only `EXIT' and `DEBUG' are accepted.
9842
9843 t. The display of trapped signals now uses the signal number if signals
9844 for which bash does not know the name are trapped.
9845
9846 u. A fix was made so that `bash -r' does not turn on restricted mode until
9847 after the startup files are executed.
9848
9849 v. A bug was fixed that occasionally caused a core dump when a variable
9850 found in the temporary environment of export/declare/readonly had a
9851 null value.
9852
9853 w. A bug that occasionally caused unallocated memory to be passed to free()
9854 when doing arithmetic substitution was fixed.
9855
9856 x. A bug that caused a buffer overrun when expanding a prompt string
9857 containing `\w' and ${#PWD} exceeded PATH_MAX was fixed.
9858
9859 y. A problem with the completion code that occasionally caused it to
9860 refer to a character before the beginning of the readline line buffer
9861 was fixed.
9862
9863 z. A bug was fixed so that the `read' builtin restarts reads when
9864 interrupted by signals other than SIGINT.
9865
9866 aa. Fixed a bug that caused a command to be freed twice when there was
9867 an evaluation error in the `eval' command.
9868
9869 2. Changes to Readline
9870
9871 a. Added a missing `extern' to a declaration in readline.h that kept
9872 readline from compiling cleanly on some systems.
9873
9874 b. The history file is now opened with mode 0600 when it is written for
9875 better security.
9876
9877 c. Changes were made to the SIGWINCH handling code so that prompt redisplay
9878 is done better.
9879
9880 d. ^G now interrupts incremental searches correctly.
9881
9882 e. A bug that caused a core dump when the set of characters to be quoted
9883 when completing words was empty was fixed.
9884
9885 ------------------------------------------------------------------------------
9886 This document details the changes between this version, bash-2.01-release,
9887 and the previous version, bash-2.01-beta2.
9888
9889 1. Changes to Bash
9890
9891 a. The `distclean' target should remove the `printenv' executable if it
9892 has been created.
9893
9894 b. The test suite was changed slightly to ensure that the error messages
9895 are printed in English.
9896
9897 c. A bug that caused the shell to dump core when a filename containing a
9898 `/' was passed to `hash' was fixed.
9899
9900 d. Pathname canonicalization now leaves a leading `//' intact, as POSIX.1
9901 requires.
9902
9903 e. A memory leak when completing commands was fixed.
9904
9905 f. A memory leak that occurred when checking the hash table for commands
9906 with relative paths was fixed.
9907
9908 ------------------------------------------------------------------------------
9909 This document details the changes between this version, bash-2.01-beta2,
9910 and the previous version, bash-2.01-beta1.
9911
9912 1. Changes to Bash
9913
9914 a. The `ulimit' builtin translates RLIM_INFINITY to the hard limit only if
9915 the current (soft) limit is less than or equal to the hard limit.
9916
9917 b. Fixed a bug that caused the bash emulation of strcasecmp to produce
9918 incorrect results.
9919
9920 c. A bug that caused memory to be freed twice when a trap handler resets
9921 the trap more than once was fixed.
9922
9923 d. A bug that caused machines where sizeof (pointer) > sizeof (int) to
9924 fail (and possibly dump core) when trying to unwind-protect a null
9925 pointer was fixed.
9926
9927 e. The startup files should not be run with job control enabled. This fix
9928 allows SIGINT to once again interrupt startup file execution.
9929
9930 f. Bash should not change the SIGPROF handler if it is set to something
9931 other than SIG_DFL.
9932
9933 g. The completion code that provides bash-specific completions for readline
9934 now quotes characters that the readline code would treat as word break
9935 characters if they appear in a file name.
9936
9937 h. The completion code now correctly quotes filenames containing a `!',
9938 even if the user attempted to use double quotes when attempting
9939 completion.
9940
9941 i. A bug that caused the shell to dump core when `disown' was called without
9942 arguments and there was no current job was fixed.
9943
9944 j. A construct like $((foo);bar) is now processed as a command substitution
9945 rather than as a bad arithmetic substitution.
9946
9947 k. A couple of bugs that caused `fc' to not obey the `cmdhist' and `lithist'
9948 shell options when editing and re-executing a series of commands were
9949 fixed.
9950
9951 l. A fix was made to the grammar -- the list of commands between `do' and
9952 `done' in the body of a `for' command should be treated the same as a
9953 while loop.
9954
9955 2. Changes to Readline
9956
9957 a. A couple of bugs that caused the history search functions to attempt to
9958 free a NULL pointer were fixed.
9959
9960 b. If the C library provides setlocale(3), readline does not need to look
9961 at various environment variables to decide whether or not to go into
9962 eight-bit mode automatically -- just check whether the current locale
9963 is not `C' or `POSIX'.
9964
9965 c. If the filename completion function finds that a directory was not closed
9966 by a previous (interrupted) completion, it closes the directory with
9967 closedir().
9968
9969 3. New Features in Bash
9970
9971 a. New bindable readline commands: history-and-alias-expand-line and
9972 alias-expand-line. The code was always in there, there was just no
9973 way to execute it.
9974
9975 ------------------------------------------------------------------------------
9976 This document details the changes between this version, bash-2.01-beta1,
9977 and the previous version, bash-2.01-alpha1.
9978
9979 1. Changes to Bash
9980
9981 a. Fixed a problem that could cause file descriptors used for process
9982 substitution to conflict with those used explicitly in redirections.
9983
9984 b. Made it easier to regenerate configure if the user changes configure.in.
9985
9986 c. ${GROUPS[0]} should always be the primary group, even on systems without
9987 multiple groups.
9988
9989 d. Spelling correction is no longer enabled by default.
9990
9991 e. Fixes to quoting problems in `bashbug'.
9992
9993 f. OS-specific configuration changes were made for: Irix 6.
9994
9995 g. OS-specific code changes were made for: QNX.
9996
9997 h. A more meaningful message is now printed when the file in /tmp for a
9998 here document cannot be created.
9999
10000 i. Many changes to the shell's variable initialization code to speed
10001 non-interactive startup.
10002
10003 j. Changes to the non-job-control code so that it does not try to open
10004 /dev/tty.
10005
10006 k. The output of `set' and `export' is once again sorted, as POSIX wants.
10007
10008 l. Fixed a problem caused by a recursive call reparsing the value of
10009 $SHELLOPTS.
10010
10011 m. The tilde code no longer calls getenv() when it's compiled as part of
10012 the shell, which should eliminate problems on systems that cannot
10013 redefine getenv(), like the NeXT OS.
10014
10015 n. Fixed a problem that caused `bash -o' or `bash +o' to not list all
10016 the shell options.
10017
10018 o. Fixed `ulimit' to convert RLIM_INFINITY to the appropriate hard limit
10019 only if the hard limit is greater than the current (soft) limit.
10020
10021 p. Fixed a problem that arose when building bash in a different directory
10022 than the source and y.tab.[ch] were remade with something other than
10023 bison. This came up most often on NetBSD.
10024
10025 q. Fixed a problem with completion -- it thought that `pwd`/[TAB] indicated
10026 an unfinished command completion (`/), which generated errors.
10027
10028 r. The bash special tilde expansions (~-, ~+) are now attempted before
10029 calling the standard tilde expansion code, which should eliminate the
10030 problems people have been seeing with this on Solaris 2.5.1.
10031
10032 s. Added support for <stdarg.h> to places where it was missing.
10033
10034 t. Changed the code that reads the output of a command substitution to not
10035 go through stdio. This reduces the memory requirements and is faster.
10036
10037 u. A number of changes to speed up export environment creation were made.
10038
10039 v. A number of memory leaks were fixed as the result of running the test
10040 scripts through Purify.
10041
10042 w. Fixed a bug that caused subshells forked to interpret executable
10043 scripts without a leading `#!' to not reinitialize the values of
10044 the shell options.
10045
10046 2. Changes to Readline
10047
10048 a. History library has less `#ifdef SHELL' code -- abstracted stuff out
10049 into application-specific function hooks.
10050
10051 b. Readline no longer calls getenv() if it's compiled as part of the shell,
10052 which should eliminate problems on systems that cannot redefine getenv(),
10053 like the NeXT OS.
10054
10055 c. Fixed translation of ESC when `untranslating' macro values.
10056
10057 d. The region kill operation now fixes the mark if it ends up beyond the
10058 boundaries of the line after the region is deleted.
10059
10060 3. New Features in Bash
10061
10062 a. New argument for `configure': `--with-curses'. This can be used to
10063 override the selection of the termcap library on systems where it is
10064 deficient.
10065
10066 ------------------------------------------------------------------------------
10067 This document details the changes between this version, bash-2.01-alpha1,
10068 and the previous version, bash-2.0-release.
10069
10070 1. Changes to Bash
10071
10072 a. System-specific configuration changes for: FreeBSD, SunOS4, Irix,
10073 MachTen, QNX 4.2, Harris Night Hawk, SunOS5.
10074
10075 b. System-specific code changes were made for: Linux, 4.4 BSD, QNX 4.2,
10076 HP-UX, AIX 4.2.
10077
10078 c. A bug that caused the exec builtin to fail because the full pathname of
10079 the command could not be found was fixed.
10080
10081 d. The code that performs output redirections is now more resistant to
10082 race conditions and possible security exploits.
10083
10084 e. A bug that caused the shell to dump core when performing pattern
10085 substitutions on variable values was fixed.
10086
10087 f. More hosts are now recognized by the auto-configuration mechanism
10088 (OpenBSD, QNX, others).
10089
10090 g. Assignments to read-only variables that attempt to convert them to
10091 arrays are now errors.
10092
10093 h. A bug that caused shell scripts using array assignments in POSIX mode
10094 to exit after the assignment was performed was fixed.
10095
10096 i. The substring expansion code is now more careful about running off the
10097 ends of the expanded variable value.
10098
10099 j. A bug that caused completion to fail if a backquoted command substitution
10100 appeared anywhere on the line was fixed.
10101
10102 k. The `source' builtin no longer turns off history if it has been enabled
10103 in a non-interactive shell.
10104
10105 l. A bug that caused the shell to crash when `disown' was given a pid
10106 instead of a job number was fixed.
10107
10108 m. The `cd' spelling correction code will not try to change to `.' if no
10109 directory entries match a single-character argument.
10110
10111 n. A bad variable name supplied to `declare', `export', or `readonly' no
10112 longer causes a non-interactive shell in POSIX mode to exit.
10113
10114 o. Some fixes were made to the test suite to handle peculiarities of
10115 various Unix versions.
10116
10117 p. The bash completion code now quotes characters that readline would
10118 treat as word breaks for completion but are not shell metacharacters.
10119
10120 q. Bad options supplied at invocation now cause a usage message to be
10121 displayed.
10122
10123 r. Fixes were made to the code that handles DEBUG traps so that the trap
10124 string is not freed inappropriately.
10125
10126 s. Some changes were made to the bash debugger in examples/bashdb -- it
10127 should be closer to working now.
10128
10129 t. A problem that caused the default filename used for mail checking to be
10130 wrong was fixed.
10131
10132 u. A fix was made to the `echo' builtin so that NUL characters printed with
10133 `echo -e' do not cause the output to be truncated.
10134
10135 v. A fix was made to the job control code so that the shell behaves better
10136 when monitor mode is enabled in a non-interactive shell.
10137
10138 w. Bash no longer catches all of the terminating signals in a non-
10139 interactive shell until a trap is set on EXIT, which should result in
10140 quicker startup.
10141
10142 x. A fix was made to the command timing code so that `time' can be used in
10143 a loop.
10144
10145 y. A fix was made to the parser so that `((cmd); cmd2)' is now parsed as
10146 a nested subshell rather than strictly as an (erroneous) arithmetic
10147 command.
10148
10149 z. A fix was made to the globbing code so that it correctly matches quoted
10150 filenames beginning with a `.'.
10151
10152 aa. A bug in `fc' that caused some multi-line commands to not be stored as
10153 one command in the history when they were re-executed after editing
10154 (with `fc -e') was fixed.
10155
10156 bb. The `ulimit' builtin now attempts to catch some classes of integer
10157 overflows.
10158
10159 cc. The command-oriented-history code no longer attempts to add `;'
10160 inappropriately when a newline appears while reading a $(...) command
10161 substitution.
10162
10163 dd. A bug that caused the shell to dump core when `help --' was executed
10164 was fixed.
10165
10166 ee. A bug that caused the shell to crash when an unset variable appeared
10167 in the body of a here document after `set -u' had been executed was
10168 fixed.
10169
10170 ff. Implicit input redirections from /dev/null for asynchronous commands
10171 are now handled better.
10172
10173 gg. A bug that caused the shell to fail to compile when configured with
10174 `--disable-readline' was fixed.
10175
10176 hh. The globbing code should now be interruptible.
10177
10178 ii. Bash now notices when the `kill' builtin is used to send SIGCONT to a
10179 stopped job and adjusts the data structures accordingly, as if `bg' had
10180 been executed instead.
10181
10182 jj. A bug that caused the shell to crash when mixing calls to `getopts'
10183 and `shift' on the same set of positional parameters was fixed.
10184
10185 kk. The command printing code now preserves the `-p' flag to `time'.
10186
10187 ll. The command printing code now handles here documents better when there
10188 are other redirections associated with the command.
10189
10190 mm. The special glibc environment variable (NNN_GNU_nonoption_argv_flags_)
10191 is no longer placed into the environment of executed commands -- users
10192 of glibc had too many problems with it.
10193
10194 nn. Reorganized the code that generates signames.h. The signal_names list
10195 is now more complete but may be slightly different (SIGABRT is favored
10196 over SIGIOT, for example). The preferred signal names are those
10197 listed in the POSIX.2 standard.
10198
10199 oo. `bashbug' now uses a filename shorter than 14 characters for its
10200 temporary file, and asks for confirmation before sending the bug
10201 report.
10202
10203 pp. A bug that caused TAB completion in vi editing mode to not be turned
10204 off when `set -o posix' was executed or back on when `set +o posix'
10205 was executed was fixed.
10206
10207 qq. A bug in the brace expansion code that caused brace expansions appearing
10208 in new-style $(...) command substitutions to be inappropriately expanded
10209 was fixed.
10210
10211 rr. A bug in the readline hook shell-expand-line that could cause memory to
10212 be inappropriately freed was fixed.
10213
10214 ss. A bug that caused some arithmetic expressions containing `&&' and `||'
10215 to be parsed with the wrong precedence has been fixed.
10216
10217 tt. References to unbound variables after `set -u' has been executed now
10218 cause the shell to exit immediately, as they should.
10219
10220 uu. A bug that caused the shell to exit inappropriately when `set -e' had
10221 been executed and a command's return status was being inverted with the
10222 `!' reserved word was fixed.
10223
10224 vv. A bug that could occasionally cause the shell to crash with a
10225 divide-by-zero error when timing a command was fixed.
10226
10227 ww. A bug that caused parameter pattern substitution to leave stray
10228 backslashes in the replacement string when the expression is in
10229 double quotes was fixed.
10230
10231 xx. The `break' and `continue' builtins now break out of all loops when an
10232 invalid count argument is supplied.
10233
10234 yy. Fixed a bug that caused PATH to be set to the empty string if
10235 `command -p' is executed with PATH unset.
10236
10237 zz. Fixed `kill -l signum' to print the signal name without the `SIG' prefix,
10238 as POSIX specifies.
10239
10240 aaa. Fixed a bug that caused the shell to crash while setting $SHELLOPTS
10241 if there were no shell options set.
10242
10243 bbb. Fixed `export -p' and `readonly -p' so that when the shell is in POSIX
10244 mode, their output is as POSIX.2 specifies.
10245
10246 ccc. Fixed a bug in `readonly' so that `readonly -a avar=(...)' actually
10247 creates an array variable.
10248
10249 ddd. Fixed a bug that prevented `time' from correctly timing background
10250 pipelines.
10251
10252 2. Changes to Readline
10253
10254 a. A bug that caused an extra newline to be printed when the cursor was on
10255 an otherwise empty line was fixed.
10256
10257 b. An instance of memory being used after it was freed was corrected.
10258
10259 c. The redisplay code now works when the prompt is longer than the screen
10260 width.
10261
10262 d. `dump-macros' is now a bindable name, as it should have been all along.
10263
10264 e. Non-printable characters are now expanded when displaying macros and
10265 their values.
10266
10267 f. The `dump-variables' and `dump-macros' commands now output a leading
10268 newline if they're called as the result of a key sequence, rather
10269 than directly by an application.
10270
10271 3. New Features in Bash
10272
10273 a. There is a new builtin array variable: GROUPS, the set of groups to which
10274 the user belongs. This is used by the test suite.
10275
10276 4. New Features in Readline
10277
10278 a. If a key sequence bound to `universal-argument' is read while reading a
10279 numeric argument started with `universal-argument', it terminates the
10280 argument but is otherwise ignored. This provides a way to insert multiple
10281 instances of a digit string, and is how GNU emacs does it.
10282
10283 ------------------------------------------------------------------------------
10284 This document details the changes between this version, bash-2.0-release,
10285 and the previous version, bash-2.0-beta3.
10286
10287 1. Changes to Bash
10288
10289 a. Fix to the `getopts' builtin so that it does the right thing when a
10290 required option argument is not present.
10291
10292 b. The completion code now updates the common prefix of matched names
10293 after FIGNORE processing is done, since any names that were removed
10294 may have changed the common prefix.
10295
10296 c. Fixed a bug that made messages in MAILPATH entries not work correctly.
10297
10298 d. Fixed a serious documentation error in the description of the new
10299 ${parameter:offset[:length]} expansion.
10300
10301 e. Fixes to make parameter substring expansion ({$param:offset[:length]})
10302 work when within double quotes.
10303
10304 f. Fixes to make ^A (CTLESC) survive an unquoted expansion of positional
10305 parameters.
10306
10307 g. Corrected a misspelling of `unlimited' in the output of `ulimit'.
10308
10309 h. Fixed a bug that caused executable scripts without a leading `#!' to
10310 occasionally pick up the wrong set of positional parameters.
10311
10312 i. Linux systems now have a working `ulimit -v', using RLIMIT_AS.
10313
10314 j. Updated config.guess so that many more machine types are recognized.
10315
10316 k. Fixed a bug with backslash-quoted slashes in the ${param/pat[/sub]}
10317 expansion.
10318
10319 l. If the shell is named `-su', and `-c command' is supplied, read and
10320 execute the login shell startup files even though the shell is not
10321 interactive. This is to support the `-' option to `su'.
10322
10323 m. Fixed a bug that caused core dumps when the DEBUG trap was ignored
10324 with `trap "" DEBUG' and a shell function was subsequently executed.
10325
10326 n. Fixed a bug that caused core dumps in the read builtin when IFS was
10327 set to the null string and the input had leading whitespace.
10328
10329 2. Changes to Readline
10330
10331 a. Fixed a bug that caused a numeric argument of 1024 to be ignored when
10332 inserting text.
10333
10334 b. Fixed the display code so that the numeric argument is displayed as it's
10335 being entered.
10336
10337 c. Fixed the numeric argument reading code so that `M-- command' is
10338 equivalent to `M--1 command', as the prompt implies.
10339
10340 3. New Features in Bash
10341
10342 a. `ulimit' now sets both hard and soft limits and reports the soft limit
10343 by default (when neither -H nor -S is specified). This is compatible
10344 with versions of sh and ksh that implement `ulimit'.
10345
10346 b. Integer constants have been extended to base 64.
10347
10348 4. New Features in Readline
10349
10350 a. The `home' and `end' keys are now bound to beginning-of-line and
10351 end-of-line, respectively, if the corresponding termcap capabilities
10352 are present.
10353
10354 ------------------------------------------------------------------------------
10355 This document details the changes between this version, bash-2.0-beta3,
10356 and the previous version, bash-2.0-beta2.
10357
10358 1. Changes to Bash
10359
10360 a. System-specific changes for: AIX 4.2, SCO 3.2v[45], HP-UX.
10361
10362 b. When in POSIX mode, variable assignments preceding a special builtin
10363 persist in the shell environment after the builtin completes.
10364
10365 c. Changed all calls to getwd() to getcwd(). Improved check for systems
10366 where the libc getcwd() calls popen(), since that breaks on some
10367 systems when job control is being used.
10368
10369 d. Fixed a bug that caused seg faults when executing scripts with the
10370 execute bit set but without a leading `#!'.
10371
10372 e. The environment passed to executed commands is never sorted.
10373
10374 f. A bug was fixed in the code that expands ${name[@]} to the number of
10375 elements in an array variable.
10376
10377 g. A bug was fixed in the array compound assignment code ( A=( ... ) ).
10378
10379 h. Window size changes now correctly propagate down to readline if
10380 the shopt `checkwinsize' option is enabled.
10381
10382 i. A fix was made in the code that expands to the length of a variable
10383 value (${#var}).
10384
10385 j. A fix was made to the command builtin so that it did not turn on the
10386 `no fork' flag inappropriately.
10387
10388 k. A fix was made to make `set -n' work more reliably.
10389
10390 l. A fix was made to the job control initialization code so that the
10391 terminal process group is set to the shell's process group if the
10392 shell changes its own process group.
10393
10394 2. Changes to Readline
10395
10396 a. System-specific changes for: SCO 3.2v[45].
10397
10398 b. The behavior of the vi-mode `.' when redoing an `i' command was changed
10399 to insert the text previously inserted by the `i' command rather than
10400 simply entering insert mode.
10401
10402 3. New features in Bash
10403
10404 a. There is a new version of the autoload function package, in
10405 examples/functions/autoload.v2, that uses arrays and provides more
10406 functionality.
10407
10408 b. Support for LC_COLLATE and locale-specific sorting of the results of
10409 pathname expansion if strcoll() is available.
10410
10411 4. New Features in Readline
10412
10413 a. Support for locale-specific sorting of completion possibilities if
10414 strcoll() is available.
10415
10416 ------------------------------------------------------------------------------
10417 This document details the changes between this version, bash-2.0-beta2,
10418 and the previous version, bash-2.0-beta1.
10419
10420 1. Changes to Bash
10421
10422 a. `pushd -' is once again equivalent to `pushd $OLDPWD'.
10423
10424 b. OS-specific changes for: SCO 3.2v[45].
10425
10426 c. A change was made to the fix for the recently-reported security hole
10427 when reading characters with octal value 255 to make it work better on
10428 systems with restartable system calls when not using readline.
10429
10430 d. Some changes were made to the test suite so that it works if you
10431 configure bash with --enable-usg-echo-default.
10432
10433 e. A fix was made to the parsing of conditional arithmetic expressions.
10434
10435 f. Illegal arithmetic bases now cause an arithmetic evaluation error rather
10436 than being silently reset.
10437
10438 g. Multiple arithmetic bases now cause an arithmetic evaluation error
10439 instead of being ignored.
10440
10441 h. A fix was made to the evaluation of ${param?word} to conform to POSIX.2.
10442
10443 i. A bug that sometimes caused array indices to be evaluated twice (which
10444 would cause errors when they contained assignment statements) was fixed.
10445
10446 j. `ulimit' was rewritten to avoid problems with getrlimit(2) returning
10447 unsigned values and to simplify the code.
10448
10449 k. A bug in the command-oriented-history code that caused it to sometimes
10450 put semicolons after right parens inappropriately was fixed.
10451
10452 l. The values inserted into the prompt by the \w and \W escape sequences
10453 are now quoted to prevent further expansion.
10454
10455 m. An interactive shell invoked as `sh' now reads and executes commands
10456 from the file named by $ENV when it starts up. If it's a login shell,
10457 it does this after reading /etc/profile and ~/.profile.
10458
10459 n. The file named by $ENV is never read by non-interactive shells.
10460
10461 2. Changes to Readline
10462
10463 a. A few changes were made to hide some macros and functions that should not
10464 be public.
10465
10466 b. An off-by-one error that caused seg faults in the history expansion code
10467 was fixed.
10468
10469 3. New Features in Bash
10470
10471 a. The ksh-style ((...)) arithmetic command was implemented. It is exactly
10472 identical to let "...". This is controlled by a new option to configure,
10473 `--enable-dparen-arithmetic', which is on by default.
10474
10475 b. There is a new #define available in config.h.top: SYS_BASH_LOGOUT. If
10476 defined to a filename, bash reads and executes commands from that file
10477 when a login shell exits. It's commented out by default.
10478
10479 c. `ulimit' has a `-l' option that reports the maximum amount of data that
10480 may be locked into memory on 4.4BSD-based systems.
10481
10482 ------------------------------------------------------------------------------
10483 This document details the changes between this version, bash-2.0-beta1,
10484 and the previous version, bash-2.0-alpha4.
10485
10486 1. Changes to Bash
10487
10488 a. A bug that sometimes caused traps to be ignored on signals the
10489 shell treats specially was fixed.
10490
10491 b. The internationalization code was changed to track the values of
10492 LC_* variables and call setlocale() as appropriate. The TEXTDOMAIN
10493 and TEXTDOMAINDIR variables are also tracked; changes cause calls
10494 to textdomain() and bindtextdomain(), if available.
10495
10496 c. A bug was fixed that sometimes caused double-quoted strings to be
10497 parsed incorrectly.
10498
10499 d. Changes were made so that the siglist code compiles correctly on
10500 Solaris 2.5.
10501
10502 e. Added `:' to the set of characters that cause word breaks for the
10503 completion code so that pathnames in assignments to $PATH can be
10504 completed.
10505
10506 f. The `select' command was fixed to print $PS3 to stderr.
10507
10508 g. Fixed an error in the manual page section describing the effect that
10509 setting and unsetting GLOBIGNORE has on the setting of the `dotglob'
10510 option.
10511
10512 h. The time conversion code now uses CLK_TCK rather than CLOCKS_PER_SEC
10513 on systems without gettimeofday() and resources.
10514
10515 i. The getopt static variables are now initialized each time a subshell
10516 is started, so subshells using `getopts' work right.
10517
10518 j. A sign-extension bug that caused a possible security hole was fixed.
10519
10520 k. The parser now reads characters between backquotes within a double-
10521 quoted string as a single word, so double quotes in the backquoted
10522 string don't terminate the enclosing double-quoted string.
10523
10524 l. A bug that caused `^O' to work incorrectly when typed as the first
10525 thing to an interactive shell was fixed.
10526
10527 m. A rarely-exercised off-by-one error in the code that quotes variable
10528 values was fixed.
10529
10530 n. Some memory and file descriptor leaks encountered when running a
10531 shell script that is executable but does not have a leading `#!'
10532 were plugged.
10533
10534 2. Changes to Readline
10535
10536 a. A bug that sometimes caused incorrect results when trying to read
10537 typeahead on systems without FIONREAD was fixed.
10538
10539 3. New Features in Bash
10540
10541 a. The command timing code now uses the value of the TIMEFORMAT variable
10542 to format and display timing statistics.
10543
10544 b. The `time' reserved word now accepts a `-p' option to force the
10545 POSIX.2 output format.
10546
10547 c. There are a couple of new and updated scripts to convert csh startup
10548 files to bash format.
10549
10550 d. There is a new builtin array variable: BASH_VERSINFO. The various
10551 members hold the parts of the version information in BASH_VERSION,
10552 plus the value of MACHTYPE.
10553
10554 4. New Features in Readline
10555
10556 a. Setting LANG to `en_US.ISO8859-1' now causes readline to enter
10557 eight-bit mode.
10558
10559 ------------------------------------------------------------------------------
10560 This document details the changes between this version, bash-2.0-alpha4,
10561 and the previous version, bash-2.0-alpha3.
10562
10563 1. Changes to Bash
10564
10565 a. There is better detection of rsh connections on Solaris 2.
10566
10567 b. Assignments to read-only variables preceding a command name are now
10568 variable assignment errors. Variable assignment errors cause
10569 non-interactive shells running in posix mode to exit.
10570
10571 c. The word tokenizer was rewritten to handle nested quotes and pairs
10572 ('', "", ``, ${...}, $(...), $[...], $'...', $"...", <(...), >(...))
10573 correctly. Some of the parameter expansion code was updated as a
10574 consequence.
10575
10576 d. A fix was made to `test' when given three arguments so that a binary
10577 operator is checked for first, before checking that the first argument
10578 is `!'.
10579
10580 e. 2''>/dev/null is no longer equivalent to 2>/dev/null.
10581
10582 f. Parser error messages were regularized, and in most cases the name of
10583 the shell script being read by a non-interactive shell is not printed
10584 twice.
10585
10586 g. A fix was made to the completion code so that it no longer removes the
10587 text the user typed in some cases.
10588
10589 h. The special glibc `getopt' environment variable is no longer put into
10590 the environment on machines with small values of ARG_MAX.
10591
10592 i. The expansion of ${...} now follows the POSIX.2 rules for finding the
10593 closing `}'.
10594
10595 j. The shell no longer displays spurious status messages for background
10596 jobs in shell scripts that complete successfully when the script is
10597 run from a terminal.
10598
10599 k. `shopt -o' now correctly updates $SHELLOPTS.
10600
10601 l. A bug that caused the $PATH searching code to return a non-executable
10602 file even when an executable file with the same name appeared later in
10603 $PATH was fixed.
10604
10605 m. The shell now does tilde expansions on unquoted `:~' in assignment
10606 statements when not in posix mode.
10607
10608 n. Variable assignment errors when a command consists only of assignments
10609 now cause non-interactive shells to exit when in posix mode.
10610
10611 o. If the variable in a `for' or `select' command is read-only, or not a
10612 legal shell identifier, a variable assignment error occurs.
10613
10614 p. `test' now handles `-a' and `-o' as binary operators when three arguments
10615 are supplied, and correctly parses `( word )' as equivalent to `word'.
10616
10617 q. `test' was fixed so that file names of the form /dev/fd/NN mean the same
10618 thing on all systems, even Linux.
10619
10620 r. Fixed a bug in the globbing code that caused patterns with multiple
10621 consecutive `*'s to not be matched correctly.
10622
10623 s. Fixed a bug that caused $PS2 to not be printed when an interactive shell
10624 not using readline is reading a here document.
10625
10626 t. Fixed a bug that caused history expansion to be performed inappropriately
10627 when a single-quoted string spanned more than one line.
10628
10629 u. `getopts' now checks that the variable name passed by the user as the
10630 second argument is a legal shell identifier and that the variable is
10631 not read-only.
10632
10633 v. Fixed `getopts' to obey POSIX.2 rules for setting $OPTIND when it
10634 encounters an error.
10635
10636 w. Fixed `set' to display variable values in a form that can be re-read.
10637
10638 x. Fixed a bug in the code that keeps track of whether or not local variables
10639 have been declared at the current level of function nesting.
10640
10641 y. Non-interactive shells in posix mode now exit if the name in a function
10642 declaration is not a legal identifier.
10643
10644 z. The job control code now ignores stopped children when the shell is not
10645 interactive.
10646
10647 aa. The `cd' builtin no longer attempts spelling correction on the directory
10648 name if the shell is not interactive, regardless of the setting of the
10649 `cdspell' option.
10650
10651 bb. Some OS-specific changes were made for SCO 3.2v[45] and AIX 4.2.
10652
10653 cc. `time' now prints its output to stderr, as POSIX.2 specifies.
10654
10655 2. Fixes to Readline
10656
10657 a. After printing possible completions, all lines of a multi-line prompt
10658 are redisplayed.
10659
10660 b. Some changes were made to the terminal handling code in rltty.c to
10661 work around AIX 4.2 bugs.
10662
10663 3. New Features in Bash
10664
10665 a. There is a new loadable builtin: sprintf, with calling syntax
10666 sprintf var format [args]
10667 This provides an easy way to simulate ksh left- and right-justified
10668 variable values.
10669
10670 b. The expansions of \h and \H in prompt strings were swapped. \h now
10671 expands to the hostname up to the first `.', as in bash-1.14.
10672
10673 4. New Features in Readline
10674
10675 a. The bash-1.14 behavior when ^M is typed while doing an incremental
10676 search was restored. ^J may now be used to terminate the search without
10677 accepting the line.
10678
10679 b. There is a new bindable variable: disable-completion. This inhibits
10680 word completion and causes the completion character to be inserted as
10681 if it had been bound to self-insert.
10682
10683 ------------------------------------------------------------------------------
10684 This document details the changes between this version, bash-2.0-alpha3,
10685 and the previous version, bash-2.0-alpha2.
10686
10687 There is now a file `COMPAT' included in the distribution that lists the
10688 user-visible incompatibilities between 1.14 and 2.0.
10689
10690 1. Changes to Bash
10691
10692 a. Some work was done so that word splitting of the rhs of assignment
10693 statements conforms more closely to historical practice.
10694
10695 b. A couple of errant memory frees were fixed.
10696
10697 c. A fix was made to the test builtin so it recognizes `<' and `>' as
10698 binary operators.
10699
10700 d. The GNU malloc in lib/malloc/malloc.c now scrambles memory as it's
10701 allocated and freed. This is to catch callers that refer to freed
10702 memory or assume something about newly-allocated memory.
10703
10704 e. Fixed a problem with conversion to 12-hour time in the prompt
10705 expansion code.
10706
10707 f. Fixed a problem with configure's argument parsing order. Now you can
10708 correctly turn on specific options after using --enable-minimal-config.
10709
10710 g. The configure script now automatically disables the use of GNU malloc
10711 on systems where it's appropriate (better than having people read the
10712 NOTES file and do it manually).
10713
10714 h. There are new prompt expansions (\v and \V) to insert version information
10715 into the prompt strings.
10716
10717 i. The default prompt string now includes the version number.
10718
10719 j. Most of the builtins that take no options were changed to use the
10720 internal getopt so they can produce proper error messages for -?
10721 and incorrect options.
10722
10723 k. Some system-specific changes were made for SVR4.2 and Solaris 2.5.
10724
10725 l. Bash now uses PATH_MAX instead of MAXPATHLEN and NAME_MAX instead of
10726 MAXNAMLEN.
10727
10728 m. A couple of problems caused by uninitialized variables were fixed.
10729
10730 n. There are a number of new loadable builtin examples: logname, basename,
10731 dirname, tty, pathchk, tee, head, and rmdir. All of these conform to
10732 POSIX.2.
10733
10734 o. Bash now notices changes in TZ and calls tzset() if present, so
10735 changing TZ will alter the time printed by prompt expansions.
10736
10737 p. The source was reorganized a bit so I don't have to wait so long for
10738 some files to compile, and to facilitate the creation of a `shell
10739 library' at some future point.
10740
10741 q. Bash no longer turns off job control if called as `sh', since the
10742 POSIX.2 spec includes job control as a standard feature.
10743
10744 r. `bash -o posix' now works as intended.
10745
10746 s. Fixed a problem with the completion code: when completing a filename
10747 that contained globbing characters, if show-all-if-ambiguous was set,
10748 the completion code would remove the user's text.
10749
10750 t. Fixed ulimit so that (hopefully) the full range of limits is available
10751 on HPUX systems.
10752
10753 u. A new `shopt' option (`hostcomplete') enables and disables hostname
10754 completion.
10755
10756 v. The shell no longer attempts to save the history on an abort(),
10757 which is usually called by programming_error().
10758
10759 w. The `-s' option to `fc' was changed to echo the command to be executed
10760 to stderr instead of stdout.
10761
10762 x. If the editor invoked by `fc -e' exits with a non-zero status, no
10763 commands are executed.
10764
10765 y. Fixed a bug that made the shopt `histverify' option work incorrectly.
10766
10767 z. There is a new variable `MACHTYPE' whose value is the GNU-style
10768 `cpu-company-system' system description as set by configure. (The
10769 values of MACHTYPE and HOSTTYPE should really be swapped.)
10770
10771 aa. The `ulimit' builtin now allows the maximum virtual memory size to be
10772 set via setrlimit(2) if RLIMIT_VMEM is defined.
10773
10774 bb. `bash -nc 'command'' no longer runs `command'.
10775
10776 2. Changes to Readline
10777
10778 a. Fixed a typo in the code that checked for FIONREAD in input.c.
10779
10780 b. Fixed a bug in the code that outputs keybindings, so things like C-\
10781 are quoted properly.
10782
10783 c. Fixed a bug in the inputrc file parsing code to handle the problems
10784 caused by inputrc files created from the output of `bind -p' in
10785 previous versions of bash. The problem was due to the bug fixed
10786 in item b above.
10787
10788 d. Readline no longer turns off the terminal's meta key, and turns it on
10789 once the first time it's called.
10790
10791 ------------------------------------------------------------------------------
10792 This file documents the changes between this version, bash-2.0-alpha2,
10793 and the previous version, bash-2.0-alpha.
10794
10795 1. Changes to Bash
10796
10797 a. The shell no longer thinks directories are executable.
10798
10799 b. `disown' has a new option, `h', which inhibits the resending of SIGHUP
10800 but does not remove the job from the jobs table.
10801
10802 c. The varargs functions in error.c now use ANSI-C `stdarg' if available.
10803
10804 d. The build process now treats the `build version' in .build as local to
10805 the build directory, so different versions built from the same source
10806 tree have different `build versions'.
10807
10808 e. Some problems with the grammar have been fixed. (It used `list' in a few
10809 productions where `compound_list' was needed. A `list' must be terminated
10810 with a newline or semicolon; a `compound_list' need not be.)
10811
10812 f. A fix was made to keep `wait' from hanging when waiting for all background
10813 jobs.
10814
10815 g. `bash --help' now writes its output to stdout, like the GNU Coding Standards
10816 specify, and includes the machine type (the value of MACHTYPE).
10817
10818 h. `bash --version' now prints more information and exits successfully, like
10819 the GNU Coding Standards specify.
10820
10821 i. The output of `time' and `times' now prints fractional seconds with three
10822 places after the decimal point.
10823
10824 j. A bug that caused process substitutions to screw up the pipeline printed
10825 by `jobs' was fixed.
10826
10827 k. Fixes were made to the code that implements $'...' and $"..." so they
10828 work as documented.
10829
10830 l. The process substitution code now opens named pipes for reading with
10831 O_NONBLOCK to avoid hanging.
10832
10833 m. Fixes were made to the trap code so the shell cleans up correctly if the
10834 trap command contains a `return' and we're executing a function or
10835 sourcing a script with `.'.
10836
10837 n. Fixes to doc/Makefile.in so that it doesn't try to remake all of the
10838 documentation (ps, dvi, etc.) on a `make install'.
10839
10840 o. Fixed an auto-increment error that caused bash -c args to sometimes dump
10841 core.
10842
10843 p. Fixed a bug that caused $HISTIGNORE to fail when the history line
10844 contained globbing characters.
10845
10846 2. Changes to Readline
10847
10848 a. There is a new string variable, rl_library_version, available for use by
10849 applications. The current value is "2.1".
10850
10851 b. A bug encountered when expand-tilde was enabled and file completion was
10852 attempted on a word beginning with `~/' was fixed.
10853
10854 c. A slight change was made to the incremental search termination behavior.
10855 ESC still terminates the search, but if input is pending or arrives
10856 within 0.1 seconds (on systems with select(2)), it is used as a prefix
10857 character. This is intended to allow users to terminate searches with
10858 the arrow keys and get the behavior they expect.