]> git.ipfire.org Git - thirdparty/bash.git/blame - CHANGES
commit bash-20090115 snapshot
[thirdparty/bash.git] / CHANGES
CommitLineData
4f562c6d
CR
1This document details the changes between this version, bash-4.0-rc1,
2and the previous version, bash-4.0-beta2.
1fa6db60
CR
3
41. Changes to Bash
5
dc9f44b3
CR
6a. Fixed a bug that caused parsing errors when a $()-style command
7 substitution was follwed immediately by a quoted newline.
8
9b. Fixed a bug that caused extended shell globbing patterns beginning with
10 `*(' to not work when used with pattern substitution word expansions.
11
12------------------------------------------------------------------------------
13This document details the changes between this version, bash-4.0-beta2,
4f562c6d 14and the previous version, bash-4.0-beta.
dc9f44b3
CR
15
161. Changes to Bash
17
626d0694
CR
18a. Fixed a bug that caused failed word expansions to set $? but not
19 PIPESTATUS.
20
21b. Changed filename completion to quote the tilde in a filename with a
22 leading tilde that exists in the current directory.
23
24c. Fixed a bug that caused a file descriptor leak when performing
25 redirections attached to a compound command.
26
27d. Fixed a bug that caused expansions of $@ and $* to not exit the shell if
28 the -u option was enabled and there were no posititional parameters.
29
30e. Fixed a bug that resulted in bash not terminating immediately if a
31 terminating signal was received while performing output.
32
33f. Fixed a bug that caused the shell to crash after creating 256 process
34 substitutions during word completion.
35
362. Changes to Readline
37
38a. Fixed a bug that caused redisplay errors when using prompts with invisible
39 characters and numeric arguments to a command in a multibyte locale.
40
41b. Fixed a bug that caused redisplay errors when using prompts with invisible
42 characters spanning more than two physical screen lines.
43
44------------------------------------------------------------------------------
45This document details the changes between this version, bash-4.0-beta,
e141c35a 46and the previous version, bash-4.0-alpha.
626d0694
CR
47
481. Changes to Bash
49
1fa6db60
CR
50a. Fixed a typo that caused a variable to be used before initialization
51 while parsing Posix-style command substitutions.
52
53b. Fixed a bug that caused stray ^? when the expansion of a parameter used
54 as part of a pattern removal expansion is empty, but part of a non-
55 empty string.
56
57c. Fixed a bug that could cause strings not converted to numbers by strtol
58 to be treated as if the conversion had been successful.
59
60d. The `return' builtin now accepts no options and requires a `--' before
61 a negative return value, as Posix requires.
62
63e. Fixed a bug that caused local variables to be created with the empty
64 string for a value rather than no value.
65
66f. Changed behavior so the shell now acts as if it received an interrupt
67 when a pipeline is killed by SIGINT while executing a list.
68
69g. Fixed a bug that caused `declare var' and `typeset var' to initialize
70 `var' to the empty string.
71
72h. Changed `bind' builtin to print a warning but proceed if invoked when
73 line editing is not active.
74
75i. Fixed a bug that caused the shell to exit when the `errexit' option is
76 set and a command in a pipeline returns a non-zero exit status.
77
78j. Fixed a bug that caused the shell to not run the exit trap in a command
79 run with `bash -c' under some circumstances.
80
81k. Fixed a bug that caused parser errors to occasionally not set $? when
82 running commands with `eval'.
83
84l. Fixed a bug that caused stray control characters when evaluating compound
85 array assignments containing $'\x7f' escapes.
86
87m. Fixed a bug that caused redirections involving file descriptor 10 as the
88 target to behave incorrectly.
89
90n. Fixed a bug that could cause memory to be freed multiple times when
91 assigning to COMP_WORDBREAKS.
92
9614c166
CR
93o. Fixed a bug that could cause NULL pointer dereferences when COMP_WORDBREAKS
94 was unset.
95
1fa6db60
CR
962. Changes to Readline
97
983. New Features in Bash
99
100a. A value of 0 for the -t option to `read' now returns success if there is
101 input available to be read from the specified file descriptor.
102
103b. CDPATH and GLOBIGNORE are ignored when the shell is running in privileged
104 mode.
105
106c. New bindable readline functions shell-forward-word and shell-backward-word,
107 which move forward and backward words delimited by shell metacharacters
108 and honor shell quoting.
109
110d. New bindable readline functions shell-backward-kill-word and shell-kill-word
111 which kill words backward and forward, but use the same word boundaries
112 as shell-forward-word and shell-backward-word.
113
1144. New Features in Readline
115
116a. If the kernel supports it, readline displays special characters
117 corresponding to a keyboard-generated signal when the signal is received.
118
119------------------------------------------------------------------------------
8e1a6eaa
CR
120This document details the changes between this version, bash-4.0-alpha,
121and the previous version, bash-3.2-release.
122
1231. Changes to Bash
124
125a. Fixed several bugs in old-style `` command substitution parsing, including
126 comment parsing and quoted string handling.
127
128b. Fixed problems parsing arguments to the [[ command's =~ regular expression
129 matching operator: metacharacter and whitespace parsing.
130
131c. Fixed a bug that caused the shell to inappropriately reuse high-numbered
132 file descriptors it used internally.
133
134d. Fixed a bug in pattern replacement word expansions that caused a `/' as
135 the first character of an expanded pattern to be mistaken for a global
136 replacement specifier.
137
138e. Fixed several problems with the asprintf and snprintf replacement functions
139 that caused hangs and crashes.
140
141f. Fixed a bug in the calculation of the current and previous job that caused
142 it to refer to incorrect jobs.
143
144g. Fixed a bug in the check for the validity of a hashed command pathname that
145 caused unnecessary hash table deletions and additions.
146
147h. Fixed a bug that caused child processes to inherit the wrong value for $!.
148
149i. Fixed a bug that caused `.' to fail to read and execute commands from non-
150 regular files such as devices or named pipes.
151
152j. Fixed a bug in printf formatting for the %x and %X expansions that occurred
153 on some systems.
154
155k. Fixed a bug that caused the shell to crash when creating temporary files if
156 $TMPDIR named a non-writable directory.
157
158l. Fixed a bug that caused the shell to ignore $TMPDIR when creating temporary
159 files under some circumstances.
160
161m. Fixed a bug that caused named pipes created by process substitution to not
162 be cleaned up.
163
164n. Fixed a bug that caused HISTTIMEFORMAT to not be honored when it appeared
165 in the initial shell environment.
166
167o. Fixed several bugs in the expansion of $* and $@ (quoted and unquoted)
168 when IFS is null or contains non-whitespace characters; the same changes
169 apply to arrays subscripted with * or @.
170
171p. Fixed several problems with pattern substitution expansions on the
bea29b7b
CR
172 positional parameters and arrays subscripted with * or @ that occurred
173 when $IFS was set to the empty string.
8e1a6eaa
CR
174
175q. Made a change to the default locale initialization code that should
176 result in better behavior from the locale-aware library functions.
177
178r. Fixed a bug that caused compacting the jobs list to drop jobs.
179
180s. Fixed a bug that caused jumps back to the top-level processing loop from
181 a builtin command to leave the shell in an inconsistent state.
182
183t. Fixed a bug that caused characters that would be escaped internally to be
184 doubled when escaped with a backslash.
185
186u. Fixed the initialization of mailboxes to not cause maildirs to be read
187 (and stat(2) called for every message file) at shell startup.
188
189v. Fixed a bug that caused the shell to not display $PS2 when the read builtin
190 reads a line continued with a backslash.
191
192w. Fixed a bug that caused errors in word splitting when $IFS contained
193 characters used for internal quoting.
194
195x. Fixed bugs that caused problems with output from shell builtins not being
196 completely displayed on some systems.
197
198y. Fixed a bug that caused output to be lost when a redirection is acting on
199 the shell's output file descriptor.
200
201z. Fixed bugs caused by shell builtins not checking for all write errors.
202
203aa. Fixed a problem that caused the shell to dump core if expansions on the
204 pattern passed to the pattern removal word expansions resulted in expansion
205 errors.
206
207bb. Fixed a bug that caused bash to loop infinitely after creating and
208 waiting for 4096 jobs.
209
210cc. Fixed a bug that caused bash to lose the status of a background job under
211 certain circumstances.
212
213dd. Fixed a bug that caused bash to not look in the temporary environment
214 when performing variable lookup under certain circumstances.
215
216ee. Fixed a bug that caused bash to close file descriptors greater than 10
217 when they were used in redirections.
218
219ff. Fixed a problem that caused the shell to attempt to read from the standard
220 input when called as `bash -i script'.
221
222gg. Fixed a memory leak and variable initialization problems when the -v option
223 was supplied to `printf' that could cause incorrect results.
224
225hh. Fixed a bug that caused the `read' builtin to count bytes when the -n option
226 was supplied, rather than (possibly multibyte) characters.
227
228ii. Fixed a bug when displaying a function due to not converting the function
229 to an external form.
230
231jj. Changed job control initialization to ensure that the shell has a tty
232 as its controlling terminal before enabling job control.
233
234kk. Fixed a bug with the `test' builtin that caused it to misinterpret
235 arguments beginning with `-' but containing more than one character.
236
237ll. Fixed bug that could cause the shell to dump core in certain cases where
238 a command sets the SIGINT disposition to the default.
239
bea29b7b
CR
240mm. Fixed a bug in the pattern replacement (affecting both word expansion
241 and the `fc' builtin) that occurred when the pattern and replacement
242 strings were empty.
8e1a6eaa
CR
243
244nn. Fixed a bug that caused an arithmetic evaluation error to disable all
245 further evaluation.
246
247oo. Fixed a bug in pathname expansion that caused it to interpret backslashes
248 in the pathname as quoting characters.
249
250pp. Fixed a bug in the replacement getcwd() implementation that could cause
251 memory to be overwritten.
252
253qq. When in Posix mode, the `ulimit' builtin now uses a block size of 512 for
254 the `-c' and `-f' options.
255
256rr. Brace expansion now allows process substitutions to pass through unchanged.
257
258ss. Fixed a problem in the command name completion code to avoid quoting
259 escaped special characters twice when the command name begins with a tilde.
260
261tt. Fixed a problem in the printf builtin that resulted in single-byte
262 output for the "'" escape, even when using multibyte characters.
263
264uu. Fixed a bug that caused the failure exit status to be lost when redirections
265 attached to a compound command failed.
266
267vv. Fixed a bug that caused the internal random number generator to not be
268 re-seeded correctly when creating a subshell.
269
270ww. Fixed a bug that could cause the bash replacement getcwd to overwrite
271 memory.
272
273xx. Fixed a bug that caused the shell to not receive SIGINT if it was sent
274 while the shell was waiting for a command substitution to terminate, and
275 make sure the exit status is correct when it does.
276
277yy. Fixed a bug that resulted in the second and subsequent children spawned
278 by a shell begun to run a command substitution being placed into the
279 wrong process group.
280
281zz. Fixed a bug that caused the results of successful tilde expansion to be
282 subject to pathname expansion and word splitting.
283
284aaa. Fixed a bug that could cause the shell to hang if it encountered an
285 error that caused it to jump back to the top processing loop during a
286 command substitution or `eval' command.
287
288bbb. Fixed a bug that caused the `read' builtin to use the tty's attributes
289 instead of those of the file descriptor passed with the -u option when
290 processing the -n and -d options.
291
292ccc. Fixed a bug that caused incorrect expansion of ${array[@]:foo} if the
293 first character of $IFS was not whitespace.
294
295ddd. Fixed a bug that occurred when scanning for the ending delimiter of a
296 ${parameter/pat/sub} expansion.
297
298eee. Fixed a bug that caused the shell to inappropriately expand command
299 substitutions in words when expanding directory names for completion.
300
301fff. Fixed a bug that caused the `fc' builtin to look too far back in the
302 history list under certain circumstances.
303
304ggg. Fixed a bug that caused a shell running in Posix mode to search $PWD for
305 a file specified as an argument to source/. when the file was not found
306 in $PATH.
307
308hhh. Fixed a bug that caused the shell to modify the case of a command word
309 found via command completion when the shell was performing case-
310 insensitive completion.
311
312iii. Fixed a bug that caused the shell to search $PATH for an argument to
313 source/. even when it contained a `/'.
314
315jjj. Fixed a bug that caused brace expansion to misorder expansions when the
316 locale did not have a collating order like aAbBcC...zZ.
317
318kkk. Fixed a bug that did not allow `set +o history' to have any effect when
319 run in a startup file or from a sourced file.
320
321lll. Fixed a bug with the precedence of the ?: conditional arithmetic operator.
322
323mmm. Fixed a bug that caused side effects of temporary variable assignments
324 to persist in the shell environment.
325
326nnn. Fixed a bug that caused the terminal to be left in non-canonical mode
327 when using editing commands that invoke the an editor on the current
328 command line.
329
330ooo. Fixed a bug that caused globbing characters and characters in $IFS to not
331 be quoted appropriately when displaying assignment statements.
332
333ppp. Fixed a bug that caused the `-e' option to be inherited when sourcing a
334 file or evaluating a command with `eval' even if the return value of the
335 command was supposed to be ignored.
336
337qqq. Fixed a bug that caused the shell to attempt to created variables with
338 invalid names if such names appeared in the initial environment.
339
340rrr. Fixed a bug with quote removal in strings where the final character is a
341 backslash.
342
343sss. Fixed a bug that caused the effects of special variables to persist even
344 when the variables were unset as part of the shell reinitializing itself
345 to execute a shell script.
346
347ttt. Fixed a bug that caused the history to not be saved after `history -c' or
348 `history -d' was executed until a sufficient number of commands had been
349 saved to the history.
350
351uuu. Bash now parses command substitutions according to Posix rules: parsing
352 the command contained in $() to find the closing delimiter.
353
354vvv. Fixed a bug that caused traps on SIGCHLD set in a SIGCHLD handler to
355 not persist.
356
357www. Fixed a bug that didn't allow SIGCHLD to interrupt the `wait' builtin
358 as Posix specifies.
359
360xxx. Invalid numeric arguments to shell builtins no longer cause the shell to
361 short-circuit any executing compound command.
362
363yyy. Fixed a bug that caused the exit status to be lost when `break' was
364 used to short-circuit a loop's execution.
365
366zzz. Fixed a bug that caused stray ^? characters to be left in expansions of
367 "${array[*]}".
368
369aaaa. Bash now prints better error messages for here documents terminated by
370 EOF and for identifying the incorrect token in an invalid arithmetic
371 expression.
372
373bbbb. Fixed a bug in the variable length word expansion that caused it to
374 incorrectly calculate the number of multibyte characters.
375
376cccc. Fixed a race condition that could result in the top-level shell setting
377 the terminal's process group to an incorrect value if the process
378 group was changed by a child of a child of the shell.
379
380dddd. Fixed a bug that caused here documents belonging to commands within a
381 compound command to be displayed in a syntactially-incorrect form, which
382 prevented them from being re-read as input.
383
384eeee. The shell displays more warnings about failures to set the locale.
385
386ffff. Fixed a bug that caused the body of a here-document to not be saved to
387 the history list.
388
bea29b7b
CR
389gggg. Fixed a bug that caused configure to incorrectly conclude that FreeBSD
390 had /dev/fd available, resulting in problems with process substitution.
391
8e1a6eaa
CR
3922. Changes to Readline
393
394a. Fixed a number of redisplay errors in environments supporting multibyte
395 characters.
396
397b. Fixed bugs in vi command mode that caused motion commands to inappropriately
398 set the mark.
399
400c. When using the arrow keys in vi insertion mode, readline allows movement
401 beyond the current end of the line (unlike command mode).
402
403d. Fixed bugs that caused readline to loop when the terminal has been taken
404 away and reads return -1/EIO.
405
406e. Fixed bugs in redisplay occurring when displaying prompts containing
407 invisible characters.
408
409f. Fixed a bug that caused the completion append character to not be reset to
410 the default after an application-specified completion function changed it.
411
bea29b7b
CR
412g. Fixed a problem that caused incorrect positioning of the cursor while in
413 emacs editing mode when moving forward at the end of a line while using
414 a locale supporting multibyte characters.
8e1a6eaa
CR
415
416h. Fixed an off-by-one error that caused readline to drop every 511th
417 character of buffered input.
418
419i. Fixed a bug that resulted in SIGTERM not being caught or cleaned up.
420
421j. Fixed redisplay bugs caused by multiline prompts with invisible characters
422 or no characters following the final newline.
423
424k. Fixed redisplay bug caused by prompts consisting solely of invisible
425 characters.
426
427l. Fixed a bug in the code that buffers characters received very quickly in
428 succession which caused characters to be dropped.
429
430m. Fixed a bug that caused readline to reference uninitialized data structures
431 if it received a SIGWINCH before completing initialzation.
432
433n. Fixed a bug that caused the vi-mode `last command' to be set incorrectly
434 and therefore unrepeatable.
435
436o. Fixed a bug that caused readline to disable echoing when it was being used
437 with an output file descriptor that was not a terminal.
438
439p. Readline now blocks SIGINT while manipulating internal data structures
440 during redisplay.
441
bea29b7b
CR
442q. Fixed a bug in redisplay that caused readline to segfault when pasting a
443 very long line (over 130,000 characters).
444
445r. Fixed bugs in redisplay when using prompts with no visible printing
446 characters.
447
8e1a6eaa
CR
4483. New Features in Bash
449
450a. When using substring expansion on the positional parameters, a starting
451 index of 0 now causes $0 to be prefixed to the list.
452
453b. The `help' builtin now prints its columns with entries sorted vertically
454 rather than horizontally.
455
456c. There is a new variable, $BASHPID, which always returns the process id of
457 the current shell.
458
459d. There is a new `autocd' option that, when enabled, causes bash to attempt
460 to `cd' to a directory name that is supplied as the first word of a
461 simple command.
462
463e. There is a new `checkjobs' option that causes the shell to check for and
464 report any running or stopped jobs at exit.
465
466f. The programmable completion code exports a new COMP_TYPE variable, set to
467 a character describing the type of completion being attempted.
468
469g. The programmable completion code exports a new COMP_KEY variable, set to
470 the character that caused the completion to be invoked (e.g., TAB).
471
472h. If creation of a child process fails due to insufficient resources, bash
473 will try again several times before reporting failure.
474
475i. The programmable completion code now uses the same set of characters as
476 readline when breaking the command line into a list of words.
477
478j. The block multiplier for the ulimit -c and -f options is now 512 when in
479 Posix mode, as Posix specifies.
480
481k. Changed the behavior of the read builtin to save any partial input received
482 in the specified variable when the read builtin times out. This also
483 results in variables specified as arguments to read to be set to the empty
484 string when there is no input available. When the read builtin times out,
485 it returns an exit status greater than 128.
486
487l. The shell now has the notion of a `compatibility level', controlled by
488 new variables settable by `shopt'. Setting this variable currently
489 restores the bash-3.1 behavior when processing quoted strings on the rhs
490 of the `=~' operator to the `[[' command.
491
492m. The `ulimit' builtin now has new -b (socket buffer size) and -T (number
493 of threads) options.
494
495n. The -p option to `declare' now displays all variable values and attributes
496 (or function values and attributes if used with -f).
497
498o. There is a new `compopt' builtin that allows completion functions to modify
499 completion options for existing completions or the completion currently
500 being executed.
501
502p. The `read' builtin has a new -i option which inserts text into the reply
503 buffer when using readline.
504
505q. A new `-E' option to the complete builtin allows control of the default
506 behavior for completion on an empty line.
507
508r. There is now limited support for completing command name words containing
509 globbing characters.
510
511s. Changed format of internal help documentation for all builtins to roughly
512 follow man page format.
513
514t. The `help' builtin now has a new -d option, to display a short description,
515 and a -m option, to print help information in a man page-like format.
516
517u. There is a new `mapfile' builtin to populate an array with lines from a
518 given file.
519
520v. If a command is not found, the shell attempts to execute a shell function
521 named `command_not_found_handle', supplying the command words as the
522 function arguments.
523
524w. There is a new shell option: `globstar'. When enabled, the globbing code
525 treats `**' specially -- it matches all directories (and files within
526 them, when appropriate) recursively.
527
528x. There is a new shell option: `dirspell'. When enabled, the filename
529 completion code performs spelling correction on directory names during
530 completion.
531
532y. The `-t' option to the `read' builtin now supports fractional timeout
533 values.
534
535z. Brace expansion now allows zero-padding of expanded numeric values and
536 will add the proper number of zeroes to make sure all values contain the
537 same number of digits.
538
539aa. There is a new bash-specific bindable readline function: `dabbrev-expand'.
540 It uses menu completion on a set of words taken from the history list.
541
542bb. The command assigned to a key sequence with `bind -x' now sets two new
543 variables in the environment of the executed command: READLINE_LINE_BUFFER
544 and READLINE_POINT. The command can change the current readline line
545 and cursor position by modifying READLINE_LINE_BUFFER and READLINE_POINT,
546 respectively.
547
548cc. There is a new >>& redirection operator, which appends the standard output
549 and standard error to the named file.
550
551dd. The parser now understands `|&' as a synonym for `2>&1 |', which redirects
552 the standard error for a command through a pipe.
553
554ee. The new `;&' case statement action list terminator causes execution to
555 continue with the action associated with the next pattern in the
556 statement rather than terminating the command.
557
558ff. The new `;;&' case statement action list terminator causes the shell to
559 test the next set of patterns after completing execution of the current
560 action, rather than terminating the command.
561
562gg. The shell understands a new variable: PROMPT_DIRTRIM. When set to an
563 integer value greater than zero, prompt expansion of \w and \W will
564 retain only that number of trailing pathname components and replace
565 the intervening characters with `...'.
566
567hh. There are new case-modifying word expansions: uppercase (^[^]) and
568 lowercase (,[,]). They can work on either the first character or
569 array element, or globally. They accept an optional shell pattern
570 that determines which characters to modify. There is an optionally-
571 configured feature to include capitalization operators.
572
573ii. The shell provides associative array variables, with the appropriate
574 support to create, delete, assign values to, and expand them.
575
576jj. The `declare' builtin now has new -l (convert value to lowercase upon
577 assignment) and -u (convert value to uppercase upon assignment) options.
578 There is an optionally-configurable -c option to capitalize a value at
579 assignment.
580
581kk. There is a new `coproc' reserved word that specifies a coprocess: an
582 asynchronous command run with two pipes connected to the creating shell.
583 Coprocs can be named. The input and output file descriptors and the
584 PID of the coprocess are available to the calling shell in variables
585 with coproc-specific names.
586
5874. New Features in Readline
588
589a. A new variable, rl_sort_completion_matches; allows applications to inhibit
590 match list sorting (but beware: some things don't work right if
591 applications do this).
592
593b. A new variable, rl_completion_invoking_key; allows applications to discover
594 the key that invoked rl_complete or rl_menu_complete.
595
596c. The functions rl_block_sigint and rl_release_sigint are now public and
597 available to calling applications who want to protect critical sections
598 (like redisplay).
599
600d. The functions rl_save_state and rl_restore_state are now public and
601 available to calling applications; documented rest of readline's state
602 flag values.
603
604e. A new user-settable variable, `history-size', allows setting the maximum
605 number of entries in the history list.
606
607f. There is a new implementation of menu completion, with several improvements
608 over the old; the most notable improvement is a better `completions
609 browsing' mode.
610
611g. The menu completion code now uses the rl_menu_completion_entry_function
612 variable, allowing applications to provide their own menu completion
613 generators.
614
615h. There is support for replacing a prefix of a pathname with a `...' when
616 displaying possible completions. This is controllable by setting the
617 `completion-prefix-display-length' variable. Matches with a common prefix
618 longer than this value have the common prefix replaced with `...'.
619
620i. There is a new `revert-all-at-newline' variable. If enabled, readline will
621 undo all outstanding changes to all history lines when `accept-line' is
622 executed.
623
624------------------------------------------------------------------------------
d3ad40de
CR
625This document details the changes between this version, bash-3.2-release,
626and the previous version, bash-3.2-beta.
627
6281. Changes to Bash
629
630a. Fixed a bug that caused the temporary environment passed to a command to
631 affect the shell's environment under certain circumstances.
632
633b. Fixed a bug in the printf builtin that caused the %q format specifier to
634 ignore empty string arguments.
635
636c. Improved multibyte character environment detection at configuration time.
637
638d. Fixed a bug in the read builtin that left spurious escape characters in the
639 input after processing backslashes when assigning to an array variable.
640
6412. Changes to Readline
642
643a. Fixed a redisplay bug that occurred in multibyte-capable locales when the
644 prompt was one character longer than the screen width.
645------------------------------------------------------------------------------
646This document details the changes between this version, bash-3.2-beta,
647and the previous version, bash-3.2-alpha.
648
6491. Changes to Bash
650
651a. Changed the lexical analyzer to treat locale-specific blank characters as
652 white space.
653
654b. Fixed a bug in command printing to avoid confusion between redirections and
655 process substitution.
656
657c. Fixed problems with cross-compiling originating from inherited environment
658 variables.
659
660d. Added write error reporting to printf builtin.
661
662e. Fixed a bug in the variable expansion code that could cause a core dump in
663 a multi-byte locale.
664
665f. Fixed a bug that caused substring expansion of a null string to return
666 incorrect results.
667
668g. BASH_COMMAND now retains its previous value while executing commands as the
669 result of a trap, as the documentation states.
670
6712. Changes to Readline
672
673a. Fixed a bug with prompt redisplay in a multi-byte locale to avoid redrawing
674 the prompt and input line multiple times.
675
676b. Fixed history expansion to not be confused by here-string redirection.
677
678c. Readline no longer treats read errors by converting them to newlines, as
679 it does with EOF. This caused partial lines to be returned from readline().
680
681------------------------------------------------------------------------------
682This document details the changes between this version, bash-3.2-alpha,
683and the previous version, bash-3.1-release.
684
6851. Changes to Bash
686
687a. Fixed a source bug that caused the minimal configuration to not compile.
688
689b. Fixed memory leaks in error handling for the `read' builtin.
690
691c. Changed the [[ and (( compound commands to set PIPESTATUS with their exit
692 status.
693
694d. Fixed some parsing problems with compound array assignments.
695
696e. Added additional configuration changes for: NetBSD (incomplete multibyte
697 character support)
698
699f. Fixed two bugs with local array variable creation when shadowing a variable
700 of the same name from a previous context.
701
702g. Fixed the `read' builtin to restore the correct set of completion functions
703 if a timeout occurs.
704
705h. Added code to defer the initialization of HISTSIZE (and its stifling of the
706 history list) until the history file is loaded, allowing a startup file to
707 override the default value.
708
709i. Tightened up the arithmetic expression parsing to produce better error
710 messages when presented with invalid operators.
711
712j. Fixed the cross-compilation support to build the signal list at shell
713 invocation rather than compile time if cross-compiling.
714
715k. Fixed multibyte support for non-gcc compilers (or compilers that do not
716 allow automatic array variable sizing based on a non-constant value).
717
718l. Several fixes to the code that manages the list of terminated jobs and
719 their exit statuses, and the list of active and recently-terminated jobs
720 to avoid pid aliasing/wraparound and allocation errors.
721
722m. Fixed a problem that allowed scripts to die due to SIGINT while waiting
723 for children, even when started in the background or otherwise ignoring
724 SIGINT.
725
726n. Fixed a bug that caused shells invoked as -/bin/bash from not being
727 recognized as login shells.
728
729o. Fixed a problem that caused shells in the background to give the terminal
730 to a process group other than the foreground shell process group.
731
732p. Fixed a problem with extracting the `varname' in ${#varname}.
733
734q. Fixed the code that handles SIGQUIT to not exit immediately -- thereby
735 calling functions that may not be called in a signal handler context --
736 but set a flag and exit afterward (like SIGINT).
737
738r. Changed the brace expansion code to skip over braces that don't begin a
739 valid matched brace expansion construct.
740
741s. Fixed `typeset' and `declare' to not require that their shell function
742 operands to be valid shell identifiers.
743
744t. Changed `test' to use access(2) with a temporary uid/euid swap when testing
745 file attributes and running setuid, and access(2) in most other cases.
746
747u. Changed completion code to not attempt command name completion on a line
748 consisting solely of whitespace when no_empty_command_completion is set.
749
750v. The `hash' builtin now prints nothing in posix mode when the hash table is
751 empty, and prints a message to that effect to stdout instead of stderr
752 when not in posix mode.
753
754w. Fixed a bug in the extended pattern matching code that caused it to fail to
755 match periods with certain patterns.
756
757x. Fixed a bug that caused the shell to dump core when performing filename
758 generation in directories with thousands of files.
759
760y. Returned to the original Bourne shell rules for parsing ``: no recursive
761 parsing of embedded quoted strings or ${...} constructs.
762
763z. The inheritence of the DEBUG, RETURN, and ERR traps is now dependent only
764 on the settings of the `functrace' and `errtrace' shell options, rather
765 than whether or not the shell is in debugging mode.
766
767aa. Fixed a problem with $HOME being converted to ~ in the expansion of
768 members of the DIRSTACK array.
769
770bb. Fixed a problem with quoted arguments to arithmetic expansions in certain
771 constructs.
772
773cc. The command word completion code now no longer returns matching directories
774 while searching $PATH.
775
776dd. Fixed a bug with zero-padding and precision handling in snprintf()
777 replacement.
778
779ee. Fixed a bug that caused the command substitution code not to take embedded
780 shell comments into account.
781
782ff. Fixed a bug that caused $((...);(...)) to be misinterpreted as an
783 arithmetic substitution.
784
785gg. Fixed a bug in the prompt expansion code that inappropriately added a
786 \001 before a \002 under certain circumstances.
787
788hh. Fixed a bug that caused `unset LANG' to not properly reset the locale
789 (previous versions would set the locale back to what it was when bash
790 was started rather than the system's "native" locale).
791
792ii. Fixed a bug that could cause file descriptors > 10 to not be closed even
793 when closed explicitly by a script.
794
795jj. Fixed a bug that caused single quotes to be stripped from ANSI-C quoting
796 inside double-quoted command substitutions.
797
798kk. Fixed a bug that could cause core dumps when `return' was executed as the
799 last element of a pipeline inside a shell function.
800
801ll. Fixed a bug that caused DEBUG trap strings to overwrite commands stored in
802 the jobs list.
803
8042. Changes to Readline
805
806a. Fixed a problem that caused segmentation faults when using readline in
807 callback mode and typing consecutive DEL characters on an empty line.
808
809b. Fixed several redisplay problems with multibyte characters, all having to
810 do with the different code paths and variable meanings between single-byte
811 and multibyte character redisplay.
812
813c. Fixed a problem with key sequence translation when presented with the
814 sequence \M-\C-x.
815
816d. Fixed a problem that prevented the `a' command in vi mode from being
817 undone and redone properly.
818
819e. Fixed a problem that prevented empty inserts in vi mode from being undone
820 properly.
821
822f. Fixed a problem that caused readline to initialize with an incorrect idea
823 of whether or not the terminal can autowrap.
824
825g. Fixed output of key bindings (like bash `bind -p') to honor the setting of
826 convert-meta and use \e where appropriate.
827
828h. Changed the default filename completion function to call the filename
829 dequoting function if the directory completion hook isn't set. This means
830 that any directory completion hooks need to dequote the directory name,
831 since application-specific hooks need to know how the word was quoted,
832 even if no other changes are made.
833
834i. Fixed a bug with creating the prompt for a non-interactive search string
835 when there are non-printing characters in the primary prompt.
836
837j. Fixed a bug that caused prompts with invisible characters to be redrawn
838 multiple times in a multibyte locale.
839
840k. Fixed a bug that could cause the key sequence scanning code to return the
841 wrong function.
842
843l. Fixed a problem with the callback interface that caused it to fail when
844 using multi-character keyboard macros.
845
846m. Fixed a bug that could cause a core dump when an edited history entry was
847 re-executed under certain conditions.
848
849n. Fixed a bug that caused readline to reference freed memory when attmpting
850 to display a portion of the prompt.
851
8523. New Features in Bash
853
854a. Changed the parameter pattern replacement functions to not anchor the
855 pattern at the beginning of the string if doing global replacement - that
856 combination doesn't make any sense.
857
858b. When running in `word expansion only' mode (--wordexp option), inhibit
859 process substitution.
860
861c. Loadable builtins now work on MacOS X 10.[34].
862
863d. Shells running in posix mode no longer set $HOME, as POSIX requires.
864
865e. The code that checks for binary files being executed as shell scripts now
866 checks only for NUL rather than any non-printing character.
867
868f. Quoting the string argument to the [[ command's =~ operator now forces
869 string matching, as with the other pattern-matching operators.
870
8714. New Features in Readline
872
873a. Calling applications can now set the keyboard timeout to 0, allowing
874 poll-like behavior.
875
876b. The value of SYS_INPUTRC (configurable at compilation time) is now used as
877 the default last-ditch startup file.
878
879c. The history file reading functions now allow windows-like \r\n line
880 terminators.
881
882------------------------------------------------------------------------------
8f01d942
CR
883This document details the changes between this version, bash-3.1-release,
884and the previous version, bash-3.1-rc2.
885
8861. Changes to Readline
887
888a. Several changes to the multibyte redisplay code to fix problems with
889 prompts containing invisible characters.
890
891------------------------------------------------------------------------------
28089d04
CR
892This document details the changes between this version, bash-3.1-rc2,
893and the previous version, bash-3.1-rc1.
894
8951. Changes to Bash
896
897a. Fixed a bug that caused a DEBUG trap to overwrite a command string that's
898 eventually attached to a background job.
899
900b. Changed some code so that filenames with leading tildes with spaces in the
901 name aren't tilde-expanded by the bash completion code.
902
903c. Fixed a bug that caused the pushd builtin to fail to change to
904 directories with leading `-'.
905
906d. Fixed a small memory leak in the programmable completion code.
907
9082. Changes to Readline
909
910a. Fixed a redisplay bug caused by moving the cursor vertically to a line
911 with invisible characters in the prompt in a multibyte locale.
912
913b. Fixed a bug that could cause the terminal special chars to be bound in the
914 wrong keymap in vi mode.
915
9163. New Features in Bash
917
918a. If compiled for strict POSIX conformance, LINES and COLUMNS may now
919 override the true terminal size.
920
9214. New Features in Readline
922
923a. A new external application-controllable variable that allows the LINES
924 and COLUMNS environment variables to set the window size regardless of
925 what the kernel returns.
926
927------------------------------------------------------------------------------
bc7bed50
CR
928This document details the changes between this version, bash-3.1-rc1,
929and the previous version, bash-3.1-beta1.
930
9311. Changes to Bash
932
d3ad40de 933a. Fixed a bug that could cause core dumps due to accessing the current
bc7bed50
CR
934 pipeline while in the middle of modifying it.
935
936b. Fixed a bug that caused pathnames with backslashes still quoting characters
937 to be passed to opendir().
938
939c. Command word completion now obeys the setting of completion-ignore-case.
940
941d. Fixed a problem with redirection that caused file descriptors greater than
942 2 to be inappropriately marked as close-on-exec.
943
944e. In Posix mode, after `wait' is called to wait for a particular process
945 explicitly, that process is removed from the list of processes known to
946 the shell, and subsequent attempts to wait for it return errors.
947
948f. Fixed a bug that caused extended pattern matching to incorrectly scan
949 backslash-escaped pattern characters.
950
951g. Fixed a synchronization problem that could cause core dumps when handling
952 a SIGWINCH.
953
954h. Fixed a bug that caused an unmatched backquote to be accepted without an
955 error when processing here documents.
956
957i. Fixed a small memory leak in the `cd' builtin.
958
959j. Fix for MacOS X so it gets the values for the HOSTTYPE, MACHTYPE, and
960 OSTYPE variables at build time, to support universal binaries.
961
962k. Fixed a bug that could cause an exit trap to return the exit status of
963 the trap command rather than the status as it was before the trap was
964 run as the shell's exit status.
965
9662. New Features in Bash
967
9683. Changes to Readline
969
970a. Fixed a bug that caused reversing the incremental search direction to
971 not work correctly.
972
973b. Fixed the vi-mode `U' command to only undo up to the first time insert mode
974 was entered, as Posix specifies.
975
6bf74e5a
CR
976c. Fixed a bug in the vi-mode `r' command that left the cursor in the wrong
977 place.
978
bc7bed50
CR
9794. New Features in Readline
980
981a. New application-callable auxiliary function, rl_variable_value, returns
982 a string corresponding to a readline variable's value.
983
984b. When parsing inputrc files and variable binding commands, the parser
985 strips trailing whitespace from values assigned to boolean variables
986 before checking them.
987
988
989------------------------------------------------------------------------------
a2e7f358
CR
990This document details the changes between this version, bash-3.1-beta1,
991and the previous version, bash-3.1-alpha1.
992
9931. Changes to Bash
994
995a. Added some system-specific signal names.
996
997b. Fixed a typo in the ulimit builtin to make `x' the right option to
998 maniuplate the limit on file locks.
999
1000c. Fixed a problem with using += to append to index 0 of an array variable
1001 when not using subscript syntax.
1002
1003d. A few changes to configure.in to remove calls to obsolete or outdated
1004 macros.
1005
1006e. Make sure changes to variables bash handles specially (e.g., LC_ALL) are
1007 made when the variable is set in the temporary environment to a command.
1008
1009f. Make sure changes to variables bash handles specially (e.g., LC_ALL) are
1010 made when the variable is modified using `printf -v'.
1011
1012g. The export environment is now remade on cygwin when HOME is changed, so
1013 DLLs bash is linked against pick up the new value. This fixes problems
1014 with tilde expansion when linking against and already-installed readline.
1015
1016h. Small fix to the logic for performing tilde expansion in posix mode, so
1017 expansion on the right-hand side of an assignment statement takes place.
1018
1019i. Fixed a bug that prevented redirections associated with a shell function
1020 from being executed when in a subshell.
1021
1022j. Fixed `source' and `.' builtins to not require an executable file when
1023 searching $PATH for a file to source.
1024
1025k. Fixed a bug that caused incorrect word splitting in a function when IFS
1026 was declared local, then unset.
1027
1028l. Fixed a problem with the `kill' builtin that prevented sending signals
1029 to a process group under certain circumstances when providing a pid < 0.
1030
1031m. When in POSIX mode, `pwd' now checks that the value it prints is the same
1032 directory as `.', even when displaying $PWD.
1033
1034n. Fixed a problem with the `read' builtin when reading a script from standard
1035 input and reading data from the same file.
1036
1037o. Fixed a problem with the `type' and `command' builtins that caused absolute
1038 pathnames to be displayed incorrectly.
1039
1040p. Some changes to the `bg' builtin for POSIX conformance.
1041
1042q. The `fc' builtin now removes the `fc' command that caused it to invoke an
1043 editor on specified history entries from the history entirely, rather than
1044 simply ignoring it.
1045
1046r. When in POSIX mode, the `v' command in vi editing mode simply invokes vi
1047 on the current command, rather than checking $FCEDIT and $EDITOR.
1048
1049s. Fixed a small memory leak in the pathname canonicalization code.
1050
1051t. Fixed a bug that caused the expanded value of a $'...' string to be
1052 incorrectly re-quoted if it occurred within a double-quoted ${...}
1053 parameter expansion.
1054
f6410766
CR
1055u. Restored default emacs-mode key binding of M-TAB to dynamic-complete-history.
1056
1057v. Fixed a bug that caused core dumps when interrupting loops running builtins
1058 on some systems.
1059
1060w. Make sure that some of the functions bash provides replacements for are
1061 not cpp defines.
1062
668f5007
CR
1063x. The code that scans embedded commands for the parser (`...` and $(...)) is
1064 now more aware of embedded comments and their effect on quoted strings.
1065
1066y. Changed the `-n' option to the `history' builtin to not reset the number of
1067 history lines read in the current session after reading the new lines from
1068 the history file if the history is being appended when it is written to
1069 the file, since the appending takes care of the problem that the adjustment
1070 was intended to solve.
1071
1072z. Improved the error message displayed when a shell script fails to execute
1c72c0cd
CR
1073 because the environment and size of command line arguments are too large.
1074
1075aa. A small fix to make sure that $HISTCMD is evaluated whenever the shell is
1076 saving commands to the history list, not just when HISTSIZE is defined.
668f5007 1077
a2e7f358
CR
10782. Changes to Readline
1079
1080a. The `change-case' command now correctly changes the case of multibyte
1081 characters.
1082
1083b. Changes to the shared library construction scripts to deal with Windows
1084 DLL naming conventions for Cygwin.
1085
1086c. Fixed the redisplay code to avoid core dumps resulting from a poorly-timed
1087 SIGWINCH.
1088
1089d. Fixed the non-incremental search code in vi mode to dispose of any current
1090 undo list when copying a line from the history into the current editing
1091 buffer.
1092
6bf74e5a
CR
1093e. The variable assignment code now ignores whitespace at the end of lines
1094 when assigning to boolean variables.
a2e7f358 1095
668f5007
CR
1096f. The `C-w' binding in incremental search now understands multibyte
1097 characters.
1098
a2e7f358
CR
10993. New Features in Bash
1100
1101a. A new configuration option, `--enable-strict-posix-default', which will
1102 build bash to be POSIX conforming by default.
1103
11044. New Features in Readline
1105
f6410766
CR
1106a. If the rl_completion_query_items is set to a value < 0, readline never
1107 asks the user whether or not to view the possible completions.
1108
a2e7f358 1109------------------------------------------------------------------------------
1569c106
CR
1110This document details the changes between this version, bash-3.1-alpha1,
1111and the previous version, bash-3.0-release.
1112
11131. Changes to Bash
1114
1115a. Fixed a bug that caused bash to crash if referencing an unset local array.
1116
1117b. Fixed a problem that caused tilde expansion to not be performed before
1118 attempting globbing word completion.
1119
1120c. Fixed an incompatibility so that a first argument to trap that's a valid
1121 signal number will be trated as a signal rather than a command to execute.
1122
1123d. Fixed ${#word} expansion to correctly compute the length of a string
1124 containing multibyte characters.
1125
1126e. Fixed a bug that caused bash to not pass the correct flags for signal
1127 disposition to child processes.
1128
1129f. Fixed a bug that caused `fc -l' to list one too many history entries.
1130
1131g. Some fixes to `fc' for POSIX conformance.
1132
1133h. Some fixes to job status display for POSIX conformance.
1134
1135i. Fixed a bug that caused `command -v' to display output if a command was not
1136 found -- it should be silent.
1137
1138j. In POSIX mode, `type' and `command -[vV]' do not report non-executable
1139 files, even if the shell will attempt to execute them.
1140
1141k. Fixed a bug that caused the `==' operator to the [[ command to not attempt
1142 extended pattern matching.
1143
1144l. Fixed the brace expansion code to handle characters whose value exceeds 128.
1145
1146m. Fixed `printf' to handle strings with a leading `\0' whose length is
1147 non-zero.
1148
1149n. Fixed a couple of problems with brace expansion where `${' was handled
1150 incorrectly.
1151
1152o. Fixed off-by-one error when calculating the upper bound of `offset' when
1153 processing the ${array[@]:offset:length} expansion.
1154
1155p. System-specific configuration changes for: FreeBSD 5.x, Interix, MacOS X
1156 10.4, Linux 2.4+ kernels, Linux 3.x kernels, Dragonfly BSD, QNX 6.x,
1157 Cygwin
1158
1159q. Fixed a bug that caused the shell to ignore the status of the rightmost
1160 command in a pipeline when the `pipefail' option was enabled.
1161
1162r. Fixed a completion bug that caused core dumps when expanding a directory
1163 name.
1164
1165s. Fixed a bug that prevented `hash -d' from removing commands from the hash
1166 table.
1167
1168t. Fixed word splitting to avoid really bad quadratic performance when
1169 expanding long lists.
1170
1171u. Fixed a bug that caused negative offsets in substring expansion to use the
1172 wrong values.
1173
1174v. Fixed a bug in printf that caused it to not return failure on write errors.
1175
1176w. Fixed a bug that caused commands in subshells to not be properly timed.
1177
1178x. The shell parser no longer attempts to parse a compound assignment specially
1179 unless in a position where an assignment statement is acceptable or parsing
1180 arguments to a builtin that accepts assignment statements.
1181
1182y. Fixed a problem that caused a `case' statement to be added to the history
1183 incorrectly as a single command if the `case word' was on one line and the
1184 `in' on another.
1185
1186z. Fixed a problem that caused internal shell quoting characters to be
1187 incorrectly quoted with backslashes under some circumstances.
1188
1189aa. The shell now performs correct word splitting when IFS contains multibyte
1190 characters.
1191
1192bb. The mail checking code now resets the cached file information if the size
1193 drops to 0, even if the times don't change.
1194
1195cc. A completed command name that is found in $PATH as well as the name of a
1196 directory in the current directory no longer has a slash appended in certain
1197 circumstances: a single instance found in $PATH when `.' is not in $PATH,
1198 and multiple instances found in $PATH, even when `.' is in $PATH.
1199
1200dd. Incorporated tilde expansion into the word expansion code rather than as a
1201 separately-called function, fixing some cases where it was performed
1202 inappropriately (e.g., after the second `=' in an assignment statement or
1203 in a double-quoted parameter expansion).
1204
1205ee. Fixed several bugs encountered when parsing compound assignment statements,
1206 so that compound assignments appearing as arguments to builtins are no
1207 longer double-expanded.
1208
1209ff. Fixed a bug in the command execution code that caused asynchronous commands
1210 containing command substitutions to not put the terminal in the wrong
1211 process group.
1212
1213gg. Bash now handles the case where the WCONTINUED flag causes waitpid() to
1214 return -1/EINVAL at runtime as well as configuration time.
1215
1216hh. Fixed parser to generate an error when the pipeline `argument' to `!' or
1217 `time' is NULL.
1218
1219ii. The shell now takes a little more care when manipulating file descriptors
1220 greater than 9 with the `exec' builtin.
1221
1222jj. Fixed a bug that caused variable assignments preceding the `command' builtin
1223 preceding a special builtin to be preserved after the command completed in
1224 POSIX mode.
1225
1226kk. Fixed a bug that allowed variables beginning with a digit to be created.
1227
1228ll. Fixed a bug that caused a \<newline> to be removed when parsing a $'...'
1229 construct.
1230
1231mm. A shell whose name begins with `-' will now be a restricted shell if the
1232 remainder of the name indicates it should be restricted.
1233
1234nn. Fixed a bug that could cause a core dump if FUNCNAME were changed or unset
1235 during a function's execution.
1236
1237oo. Fixed a bug that caused executing a `return' in a function to not execute
1238 a RETURN trap. The RETURN trap is inherited by shell functions only if
1239 function tracing is globally enabled or has been enabled for that function.
1240
1241pp. Fixed cases where var[@] was not handled exactly like var, when var is a
1242 scalar variable.
1243
1244qq. Fixed a bug that caused the first character after a SIGINT to be discarded
1245 under certain circumstances.
1246
1247rr. Fixed exit status code so that a suspended job returns 128+signal as its
1248 exit status (preventing commands after it in `&&' lists from being
1249 executed).
1250
1251ss. Fixed a bug that caused the shell parser state to be changed by executing
1252 a shell function as a result of word completion.
1253
1254tt. Fixed a long-standing bug that caused '\177' characters in variable
1255 values to be discarded when expanded in double-quoted strings.
1256
1257uu. Fixed a bug that caused $RANDOM to be re-seeded multiple times in a
1258 subshell environment.
1259
1260vv. Extensive changes to the job management code to avoid the pid-reuse and
1261 pid-aliasing problems caused by retaining the exit status of too many jobs,
1262 but still retain as many background job statuses as POSIX requires.
1263
1264ww. Fixed a parser bug in processing \<newline> that caused things like
1265
1266 ((echo 5) \
1267 (echo 6))
1268
1269 to not work correctly.
1270
1271xx. `pwd -P' now sets $PWD to a directory name containing no symbolic links
1272 when in posix mode, as POSIX requires.
1273
1274yy. In posix mode, bash no longer sets $PWD to a name containing no symbolic
1275 links if a directory is chosen from $CDPATH.
1276
1277zz. The word splitting code now treats an IFS character that is not space,
1278 tab, or newline and any adjacent IFS white space as a single delimiter, as
1279 SUSv3/XPG6 require.
1280
1281aaa. The `read' builtin now checks whether or not the number of fields read is
1282 exactly the same as the number of variables instead of just assigning the
1283 rest of the line (minus any trailing IFS white space) to the last
1284 variable. This is what POSIX/SUS/XPG all require.
1285
1286bbb. Fixed a bug that caused `read' to always check whether or not fd 0 was a
1287 pipe, even when reading from another file descriptor.
1288
1289ccc. Fixed a bug that caused short-circuiting of execution even if the return
1290 value was being inverted.
1291
1292ddd. Fixed a bug that caused a core dump while decoding \W escapes in PS1 if
1293 PWD was unset.
1294
1295eee. Fixed a bug in `read' that counted internal quoting characters for the
1296 purposes of `read -n'.
1297
1298fff. Fixed a bug so that a function definition in a pipeline causes a child
1299 process to be forked at the right time.
1300
1301ggg. Bash will not attempt to link against a readline library that doesn't
1302 have rl_gnu_readline_p == 1.
1303
1304hhh. Fixed a bug that caused `read' to consume one too many characters when
1305 reading a fixed number of characters and the Nth character is a backslash.
1306
1307iii. Fixed a bug that caused `unset' on variables in the temporary environment
1308 to leave them set when `unset' completed.
1309
1310jjj. Fixed a bug that caused bash to close fd 2 if an `exec' failed and the
1311 shell didn't exit.
1312
1313kkk. The completion code is more careful to not turn `/' or `///' into `//',
1314 for those systems on which `//' has special meaning.
1315
1316lll. Fixed a bug that caused command substitution in asynchronous commands to
1317 close the wrong file descriptors.
1318
1319mmm. The shell no longer prints status messages about terminated background
1320 processes unless job control is active.
1321
1322nnn. Fixed a bug that prevented multiple consecutive invocations of `history -s'
1323 from adding all the commands to the history list.
1324
1325ooo. Added a couple of changes to make arithmetic expansion more consistent in
1326 all its contexts (still not perfect).
1327
1328ppp. Fixed a bug that caused the parser to occasionally not find the right
1329 terminating "`" in an old-style command substitution.
1330
1331qqq. Fixed a bug that caused core dumps when the shell was reading its non-
1332 interactive input from fd 0 and fd 0 was duplicated and restored using a
1333 combination of `exec' (to save) and redirection (to restore).
1334
f5635ecd
CR
1335rrr. Fixed a problem that caused loops in sourced scripts to not be cleaned
1336 up properly when a `return' is executed.
1337
1338sss. Change internal command substitution completion function to append a slash
1339 to directory names in the command.
1340
1569c106
CR
13412. Changes to Readline
1342
1343a. Fixed a bug that caused multiliine prompts to be wrapped and displayed
1344 incorrectly.
1345
1346b. Fixed a bug that caused ^P/^N in emacs mode to fail to display the current
1347 line correctly.
1348
1349c. Fixed a problem in computing the number of invisible characters on the first
1350 line of a prompt whose length exceeds the screen width.
1351
1352d. Fixed vi-mode searching so that failure preserves the current line rather
1353 than the last line in the history list.
1354
1355e. Fixed the vi-mode `~' command (change-case) to have the correct behavior at
1356 end-of-line when manipulating multibyte characters.
1357
1358f. Fixed the vi-mode `r' command (change-char) to have the correct behavior at
1359 end-of-line when manipulating multibyte characters.
1360
1361g. Fixed multiple bugs in the redisplay of multibyte characters: displaying
1362 prompts longer than the screen width containing multibyte characters,
1363
1364h. Fix the calculation of the number of physical characters in the prompt
1365 string when it contains multibyte characters.
1366
1367i. A non-zero value for the `rl_complete_suppress_append' variable now causes
1368 no `/' to be appended to a directory name.
1369
1370j. Fixed forward-word and backward-word to work when words contained
1371 multibyte characters.
1372
1373k. Fixed a bug in finding the delimiter of a `?' substring when performing
1374 history expansion in a locale that supports multibyte characters.
1375
1376l. Fixed a memory leak caused by not freeing the timestamp in a history entry.
1377
1378m. Fixed a bug that caused "\M-x" style key bindings to not obey the setting
1379 of the `convert-meta' variable.
1380
1381n. Fixed saving and restoring primary prompt when prompting for incremental
1382 and non-incremental searches; search prompts now display multibyte
1383 characters correctly.
1384
1385o. Fixed a bug that caused keys originally bound to self-insert but shadowed
1386 by a multi-character key sequence to not be inserted.
1387
1388p. Fixed code so rl_prep_term_function and rl_deprep_term_function aren't
1389 dereferenced if NULL (matching the documentation).
1390
1391q. Extensive changes to readline to add enough state so that commands
1392 requiring additional characters (searches, multi-key sequences, numeric
1393 arguments, commands requiring an additional specifier character like
1394 vi-mode change-char, etc.) work without synchronously waiting for
1395 additional input.
1396
1397r. Lots of changes so readline builds and runs on MinGW.
1398
1399s. Readline no longer tries to modify the terminal settings when running in
1400 callback mode.
1401
f5635ecd
CR
1402t. The Readline display code no longer sets the location of the last invisible
1403 character in the prompt if the \[\] sequence is empty.
1404
1569c106
CR
14053. New Features in Bash
1406
1407a. Bash now understands LC_TIME as a special variable so that time display
1408 tracks the current locale.
1409
1410b. BASH_ARGC, BASH_ARGV, BASH_SOURCE, and BASH_LINENO are no longer created
1411 as `invisible' variables and may not be unset.
1412
1413c. In POSIX mode, if `xpg_echo' option is enabled, the `echo' builtin doesn't
1414 try to interpret any options at all, as POSIX requires.
1415
1416d. The `bg' builtin now accepts multiple arguments, as POSIX seems to specify.
1417
1418e. Fixed vi-mode word completion and glob expansion to perform tilde
1419 expansion.
1420
1421f. The `**' mathematic exponentiation operator is now right-associative.
1422
1423g. The `ulimit' builtin has new options: -i (max number of pending signals),
1424 -q (max size of POSIX message queues), and -x (max number of file locks).
1425
1426h. A bare `%' once again expands to the current job when used as a job
1427 specifier.
1428
1429i. The `+=' assignment operator (append to the value of a string or array) is
1430 now supported for assignment statements and arguments to builtin commands
1431 that accept assignment statements.
1432
1433j. BASH_COMMAND now preserves its value when a DEBUG trap is executed.
1434
1435k. The `gnu_errfmt' option is enabled automatically if the shell is running
1436 in an emacs terminal window.
1437
1438l. New configuration option: --single-help-strings. Causes long help text
1439 to be written as a single string; intended to ease translation.
1440
1441m. The COMP_WORDBREAKS variable now causes the list of word break characters
1442 to be emptied when the variable is unset.
1443
1444n. An unquoted expansion of $* when $IFS is empty now causes the positional
1445 parameters to be concatenated if the expansion doesn't undergo word
1446 splitting.
1447
1448o. Bash now inherits $_ from the environment if it appears there at startup.
1449
1450p. New shell option: nocasematch. If non-zero, shell pattern matching ignores
1451 case when used by `case' and `[[' commands.
1452
1453q. The `printf' builtin takes a new option: -v var. That causes the output
1454 to be placed into var instead of on stdout.
1455
1456r. By default, the shell no longer reports processes dying from SIGPIPE.
1457
1458s. Bash now sets the extern variable `environ' to the export environment it
1459 creates, so C library functions that call getenv() (and can't use the
1460 shell-provided replacement) get current values of environment variables.
1461
14624. New Features in Readline
1463
1464a. The key sequence sent by the keypad `delete' key is now automatically
1465 bound to delete-char.
1466
1467b. A negative argument to menu-complete now cycles backward through the
1468 completion list.
1469
1470c. A new bindable readline variable: bind-tty-special-chars. If non-zero,
1471 readline will bind the terminal special characters to their readline
1472 equivalents when it's called (on by default).
1473
1474d. New bindable command: vi-rubout. Saves deleted text for possible
1475 reinsertion, as with any vi-mode `text modification' command; `X' is bound
1476 to this in vi command mode.
1477
1478------------------------------------------------------------------------------
3ede1caa
CR
1479This document details the changes between this version, bash-3.0-release,
1480and the previous version, bash-3.0-rc1.
1481
14821. Changes to Bash
1483
1484a. Fixed a boundary overrun that could cause segmentation faults when the
1485 completion code hands an incomplete construct to the word expansion
1486 functions.
1487
1488b. Changed posix mode behavior so that an error in a variable assignment
1489 preceding a special builtin causes a non-interactive shell to exit.
1490
1491c. Change the directory expansion portion of the completion code to not
1492 expand embedded command substitutions if the directory name appears in
1493 the file system.
1494
a5e25162
CR
1495d. Fixed a problem that caused `bash -r' to turn on restrictions before
1496 reading the startup files.
1497
1498e. Fixed a problem with the default operation of the `umask' builtin.
1499
3ede1caa
CR
15002. Changes to Readline
1501
1502a. Fixed a problem with readline saving the contents of the current line
1503 before beginning a non-interactive search.
1504
a5e25162
CR
1505b. Fixed a problem with EOF detection when using rl_event_hook.
1506
1507c. Fixed a problem with the vi mode `p' and `P' commands ignoring numeric
1508 arguments.
1509
3ede1caa 1510------------------------------------------------------------------------------
762a763b
CR
1511This document details the changes between this version, bash-3.0-rc1,
1512and the previous version, bash-3.0-beta1.
1513
15141. Changes to Bash
1515
1516a. Fixed a bug that caused incorrect behavior when referecing element 0 of
1517 an array using $array, element 0 was unset, and `set -u' was enabled.
1518
1519b. System-specific changes for: SCO Unix 3.2, Tandem.
1520
1521c. Fixed a bug that caused inappropriate word splitting when a variable was
1522 expanded within a double-quoted string that also included $@.
1523
1524d. Fixed a bug that caused `pwd' to not display anything in physical mode
1525 when the file system had changed underneath the shell.
1526
1527e. Fixed a bug in the pre- and post- increment and decrement parsing in the
1528 expression evaluator that caused errors when the operands and corresponding
1529 operators were separated by whitespace.
f085a21f
CR
1530
1531f. Fixed a bug that caused `history -p' to add an entry to the history list,
1532 counter to the documentation. (Keeps the history expansions invoked by
1533 emacs-mode command line editing from doing that as well.)
1534
1535g. Fixed a bug that could cause a core dump if `cd' is asked to print out a
1536 pathname longer than PATH_MAX characters.
1537
1538h. Fixed a bug that caused jobs to be put into the wrong process group under
1539 some circumstances after enabling job control with `set -m'.
1540
1541i. `unalias' now returns failure if no alias name arguments are supplied.
1542
1543j. Documented the characters not allowed to appear in an alias name.
1544
1545k. $* is no longer expanded as if in double quotes when it appears in the
1546 body of a here document, as the SUS seems to require.
1547
1548l. The `bashbug' script now uses a directory in $TMPDIR for exclusive
1549 access rather than trying to guess how the underlying OS provides for
1550 secure temporary file creation.
1551
1552m. Fixed a few problems with `cd' and `pwd' when asked to operate on pathnames
1553 longer than PATH_MAX characters.
1554
1555n. Fixed a memory leak caused when creating multiple local array variables
1556 with identical names.
1557
61deeb13
CR
1558o. Fixed a problem with calls to getcwd() so that bash now operates better
1559 when the full pathname to the current directory is longer than PATH_MAX
1560 bytes.
1561
1562p. The `trap' builtin now reports an error if a single non-signal argument
1563 is specified.
1564
56299fa5
CR
1565q. Fixed a bug that caused `umask' to not work correctly when presented
1566 with a mask of all 0s.
1567
1568r. When `getopts' reaches the end of options, OPTARG is unset, as POSIX
1569 appears to specify.
1570
1571s. Interactive mode now depends on whether or not stdin and stderr are
1572 connected to a tty; formerly it was stdin and stdout. POSIX requires
1573 this.
1574
1575t. Fixed vi-mode completion to work more as POSIX specifies (e.g., doing the
1576 right kind of filename generation).
1577
f085a21f
CR
15782. Changes to Readline
1579
1580a. Fixed a problem that could cause readline to refer to freed memory when
1581 moving between history lines while doing searches.
1582
1583b. Improvements to the code that expands and displays prompt strings
1584 containing multibyte characters.
1585
1586c. Fixed a problem with vi-mode not correctly remembering the numeric argument
1587 to the last `c'hange command for later use with `.'.
1588
1589d. Fixed a bug in vi-mode that caused multi-digit count arguments to work
1590 incorrectly.
1591
1592e. Fixed a problem in vi-mode that caused the last text modification command
1593 to not be remembered across different command lines.
1594
56299fa5
CR
1595f. Fixed problems with changing characters and changing case at the end of
1596 the line.
1597
f085a21f
CR
15983. New Features in Bash
1599
1600a. The `jobs', `kill', and `wait' builtins now accept job control notation
1601 even if job control is not enabled.
1602
61deeb13
CR
1603b. The historical behavior of `trap' that allows a missing `action' argument
1604 to cause each specified signal's handling to be reset to its default is
1605 now only supported when `trap' is given a single non-option argument.
1606
56299fa5
CR
16074. New Features in Readline
1608
1609a. When listing completions, directories have a `/' appended if the
1610 `mark-directories' option has been enabled.
1611
762a763b 1612------------------------------------------------------------------------------
12d937f9
CR
1613This document details the changes between this version, bash-3.0-beta1,
1614and the previous version, bash-3.0-alpha.
d3a24ed2
CR
1615
16161. Changes to Bash
1617
545f34cf
CR
1618a. Fixes to build correctly when arrays are not compiled into the shell.
1619
1620b. Fixed command substitution to run any exit trap defined in the command
1621 substitution before returning; the exit trap is not inherited from the
1622 calling shell.
1623
1624c. Fixes to process group synchronization code so that every child process
1625 attempts to set the terminal's process group; fixes some synchronization
1626 problems on Linux kernels that schedule the child to always run before
1627 the parent.
1628
1629d. Fixed processing of octal and hex constants in printf builtin for POSIX.2
1630 compliance.
1631
1632e. Fixed a couple of core dumps in the pattern removal code.
1633
1634f. Fixes to the array subrange extraction code to deal better with sparse
1635 arrays.
1636
1637g. Parser errors and other errors that result in the shell exiting now cause
1638 the exit trap to be run.
1639
1640h. Change the command substitution completion functions to not append any
1641 closing quote, because it would be inserted a closing "`" or ")".
1642
1643i. Fix history initialization so assignments to $histchars made in startup
1644 files are honored.
1645
1646j. If an exit trap does not contain a call to `exit', the shell now uses
1647 the exit status of the last command executed before the trap as the exit
1648 status of the shell.
1649
1650k. The parser now prompts with $PS2 if it reads a newline while parsing a
1651 compound array assignment statement.
1652
1653l. When performing a compound array assignment, the parser doesn't treat
1654 words of the form [index]=value as assignments if they're the result of
1655 expansions.
1656
1657m. Fixed a bug that caused `return' executed in a trap command to make the
1658 shell think it was still running the trap.
1659
1660n. Fixed the value of errno set by the pathname canonicalization functions.
1661
1662o. Changed the grammar so that `time' alone on a line times a null command
1663 rather than being a syntax error.
1664
d11b8b46 1665p. The pattern substitution code no longer performs quote removal on the
545f34cf
CR
1666 pattern before trying to match it, as the pattern removal functions do.
1667
1668q. Fixed a bug that could cause core dumps when checking whether a quoted
1669 command name was being completed.
1670
1671r. Fixes to the pattern removal and pattern replacement expansions to deal
f9732a04 1672 with multibyte characters better (and faster).
545f34cf
CR
1673
1674s. Fix to the substring expansion (${param:off[:len]}) to deal with (possibly
1675 multibyte) characters instead of raw bytes.
1676
12d937f9
CR
1677t. Fixed a bug that caused some key bindings set in an inputrc to be ignored
1678 at shell startup.
1679
1680u. Fixed a bug that caused unsetting a local variable within a function to
1681 not work correctly.
1682
1683v. Fixed a bug that caused invalid variables to be created when using
1684 `read -a'.
1685
1686w. Fixed a bug that caused "$@" to expand incorrectly when used as the right
1687 hand side of a parameter expansion such as ${word:="$@"} if the first
1688 character of $IFS was not a space.
1689
f9732a04
CR
1690x. Fixed a slight cosmetic problem when printing commands containing a
1691 `>&word' redirection.
1692
fb65be05
CR
1693y. Fixed a problem that could cause here documents to not be created correctly
1694 if the system temporary directory did not allow writing.
1695
545f34cf
CR
16962. Changes to Readline
1697
1698a. Change to history expansion functions to treat `^' as equivalent to word
1699 one, as the documention states.
1700
1701b. Some changes to the display code to improve display and redisplay of
1702 multibyte characters.
1703
1704c. Changes to speed up the multibyte character redisplay code.
1705
1706d. Fixed a bug in the vi-mode `E' command that caused it to skip over the
1707 last character of a word if invoked while point was on the word's
1708 next-to-last character.
1709
1710e. Fixed a bug that could cause incorrect filename quoting when
1711 case-insensitive completion was enabled and the word being completed
1712 contained backslashes quoting word break characters.
1713
1714f. Fixed a bug in redisplay triggered when the prompt string contains
1715 invisible characters.
1716
43cdcad8
CR
1717g. Fixed some display (and other) bugs encountered in multibyte locales
1718 when a non-ascii character was the last character on a line.
1719
1720h. Fixed some display bugs caused by multibyte characters in prompt strings.
1721
704a1a2a
CR
1722i. Fixed a problem with history expansion caused by non-whitespace characters
1723 used as history word delimiters.
1724
545f34cf
CR
17253. New Features in Bash
1726
1727a. printf builtin understands two new escape sequences: \" and \?.
1728
1729b. `echo -e' understands two new escape sequences: \" and \?.
1730
1731c. The GNU `gettext' package and libintl have been integrated; the shell's
1732 messages can be translated into different languages.
1733
12d937f9
CR
1734d. The `\W' prompt expansion now abbreviates $HOME as `~', like `\w'.
1735
1736e. The error message printed when bash cannot open a shell script supplied
1737 as argument 1 now includes the name of the shell, to better identify
1738 the error as coming from bash.
1739
545f34cf
CR
17404. New Features in Readline
1741
1742a. New application variable, rl_completion_quote_character, set to any
1743 quote character readline finds before it calls the application completion
1744 function.
1745
1746b. New application variable, rl_completion_suppress_quote, settable by an
1747 application completion function. If set to non-zero, readline does not
1748 attempt to append a closing quote to a completed word.
1749
1750c. New application variable, rl_completion_found_quote, set to a non-zero
1751 value if readline determines that the word to be completed is quoted.
1752 Set before readline calls any application completion function.
1753
113d85a4
CR
1754d. New function hook, rl_completion_word_break_hook, called when readline
1755 needs to break a line into words when completion is attempted. Allows
1756 the word break characters to vary based on position in the line.
1757
1758e. New bindable command: unix-filename-rubout. Does the same thing as
1759 unix-word-rubout, but adds `/' to the set of word delimiters.
1760
545f34cf
CR
1761------------------------------------------------------------------------------
1762This document details the changes between this version, bash-3.0-alpha,
1763and the previous version, bash-2.05b-release.
1764
17651. Changes to Bash
1766
d3a24ed2
CR
1767a. Fixes so that the shell will compile without some of the default options
1768 defined.
1769
1770b. Fixed an error message that did not pass enough arguments to printf.
1771
1772c. Fixed a bug that caused input redirection to a builtin inside a script
1773 being read from standard input to result in the rest of the already-
1774 read and buffered script to be discarded.
1775
1776d. Fixed a bug that caused subshell initialization to close the file
1777 descriptor from which the shell was reading a script under certain
1778 circumstances.
1779
1780e. Fixed a bug that caused the shell to not advance a string pointer over
1781 a null wide character when doing string operations.
1782
1783f. Fixed the internal logout code so that shells that time out waiting for
1784 input (using $TMOUT) run ~/.bash_logout.
1785
1786g. Portability and configuration changes for: cygwin, HP/UX, GNU/FreeBSD.
1787
1788h. The parser no longer adds implicit double quotes to ((...)) arithmetic
1789 commands.
1790
1791i. The ((...)) arithmetic command evaluation code was fixed to not dump core
1792 when the expanded string is null.
1793
1794j. The ((...)) arithmetic command evaluation code was fixed to not perform
1795 variable assignments while expanding the expression.
1796
1797k. Fixed a bug that caused word splitting to be performed incorrectly when
1798 IFS is set, but null.
1799
1800l. Fixed a bug in brace expansion that caused a quoted `$' preceding an
1801 open brace to inhibit brace expansion.
1802
1803m. Fixed a bug that caused a leading `-' in the shell's name to cause it to
1804 not be recognized as a restricted shell.
1805
1806n. Fixed a bug in the arithmetic evaluation code that could cause longjmps
1807 to an invalid location and result in a core dump.
1808
1809o. Fixed a bug in the calculation of how many history lines are new in a
1810 single shell session when reading new history lines from a file with
1811 `history -n'.
1812
1813p. Fixed a bug in pathname canonicalization that caused the shell to dump
1814 core when presented with a pathname longer than PATH_MAX.
1815
1816q. Fixed the parser so that it doesn't try to compare a char variable to
1817 EOF, which fails when chars are unsigned.
1818
1819r. Fixed a bug in the simple command execution code that caused occasional
1820 core dumps.
1821
1822s. The shell does a better job of saving any partial parsing state during
1823 operations which cause a command to be executed while a line is being
1824 entered and parsed.
1825
1826t. The completion code now splits words more like the expansion code when
1827 $IFS is used to split.
1828
1829u. The locale code does a better job of recomputing the various locale
1830 variable values when LC_ALL is unset.
1831
1832v. The programmable completion code does a better job of dequoting expanded
1833 word lists before comparing them against the word to be matched.
1834
1835w. The shell no longer seg faults if the expanded value of $PS4 is null
1836 and `set -x' is enabled.
1837
1838x. Fixed a bug that caused core dumps when a here string expanded to NULL.
1839
1840y. The mail checking code now makes sure the mailbox is bigger before
1841 reporting the existence of new mail.
1842
1843z. The parser does not try to expand $'...' and $"..." when the appear
1844 within double quotes unless the `extquote' option has been enabled with
1845 `shopt'. For backwards compatibility, it is enabled by default.
1846
1847aa. Fixed a bug that caused `for x; do ...' and `select x; do ... to use
1848 $@ instead of "$@" for the implicit list of arguments.
1849
1850bb. Fixed a bug that caused a subshell of a restricted shell (e.g., one
1851 spawned to execute a pipeline) to not exit immediately if attempting
1852 to use a command containing a slash.
1853
1854cc. Fixed a problem with empty replacements for a pattern that doesn't match
1855 when performing ${param/word/} expansion.
1856
1857dd. Word expansions performed while expanding redirections no longer search
1858 a command's temporary environment to expand variable values.
1859
1860ee. Improvements to the alias expansion code when expanding subsequent words
1861 because an aliase's value ends with a space.
1862
1863ff. `cd -' now prints the current working directory after a successful chdir
1864 even when the shell is not interactive, as the standard requires.
1865
1866gg. The shell does a better job of ensuring a child process dies of SIGINT
1867 before resending SIGINT to itself.
1868
1869hh. The arithmetic expansion variable assignment code now does the right
1870 thing when assigning to `special' variables like OPTIND.
1871
1872ii. When history expansion verification is enabled, the bash readline helper
1873 functions that do history expansion on the current line don't print
1874 the results.
1875
1876jj. Fixed bugs with multiple consecutive alias expansion when one of the
1877 expansions ends with a space.
1878
1879kk. Fixed a problem in the programmable completion code that could cause core
1880 dumps when trying to initialize a set of possible completions from a
1881 list of variables.
1882
1883ll. The \[ and \] escape characters are now ignored when decoding the prompt
1884 string if the shell is started with editing disabled.
1885
1886mm. Fixed a bug that could leave extra characters in a string when doing
1887 quoted null character removal.
1888
1889nn. Command substitution and other subshell operations no longer reset the
1890 line number (aids the bash debugger).
1891
1892oo. Better line number management when executing simple commands, conditional
1893 commands, for commands, and select commands.
1894
1895pp. The globbing code now uses malloc, with its better failure properties,
1896 rather than alloca().
1897
1898qq. Fixed a bug that caused expansions like #{a[2]:=value} to create the
1899 appropriate array element instead of a variable named `a[2]'.
1900
1901rr. Fixed a bug in the handling of a `?(...)' pattern immediately following
1902 a `*' when extglob is enabled.
1903
1904ss. Fixed a bug that caused a `return' invoked in an exit trap when exit is
1905 invoked in a function to misbehave.
1906
1907tt. Fixed a bug that caused CTLESC and CTLNUL characters to not be escaped
1908 by the internal shell string quoting functions.
1909
5e13499c
CR
1910uu. Fixed a bug that caused quoted null characters in an expanded word list
1911 to be inappropriately assigned to an array variable when using `read -a'.
d3a24ed2
CR
1912
1913vv. Fixed a bug that caused redirections accompanying a null command to persist
1914 in the current shell.
1915
1916ww. Fixed a bug that caused the prompt to be printed when the shell was
1917 expanding a multiline alias.
1918
1919xx. Fixed a bug that resulted in core dumps when the completion for a command
1920 changed the compspec.
1921
1922yy. Fixed a bug that caused evaluation of programmable completions to print
1923 notifications of completed jobs.
1924
1925zz. Bash now disables line editing when $EMACS == `t' and $TERM == `dumb'
1926 (which is what emacs shell windows do).
1927
1928aaa. In posix mode, `kill -l' causes signal names to be displayed without
1929 a leading `SIG'.
1930
1931bbb. Clear error flag on standard output so it doesn't persist across multiple
1932 builtin commands.
1933
1934ccc. In posix mode, `alias' displays alias values without the leading `alias',
1935 so the output cannot be used as subsequent input.
1936
1937ddd. In posix mode, the `trap' builtin doesn't check whether or not its
1938 first argument is a signal specification and revert the signal handling
1939 to its original disposition if it is.
1940
1941eee. Fixed several bugs in the handling of "$*" and "${array[*]}" by the
1942 pattern substitution and removal expansions.
1943
1944fff. Fixed several problems with the handling of ${array[@]}, ${array[*]},
1945 $@, and $* by the indirect variable expansion code.
1946
1947ggg. Fixed a bug that did not allow `time' to be aliased.
1948
1949hhh. Improved the mail checking code so it won't check (and possibly cause an
1950 NFS file system mount) until MAILPATH or MAIL is given a value -- there
1951 is no default if DEFAULT_MAIL_DIRECTORY is not defined at compile time.
1952 (It is computed by configure, but can be #undef'd in config-bot.h.)
1953
1954iii. If the `chkwinsize' option is enabled, the shell checks for window size
1955 changes if a child process exits due to a signal.
1956
1957jjj. Removed the attempts to avoid adding a slash at the end of a completed
1958 executable name if there was a directory with the same name in the
1959 current directory.
1960
1961kkk. Fixed PATH lookup code so it treats the permission bits separately for
1962 owner, group, and other, rather than checking them all.
1963
1964lll. Fixed the locale code to reset the parser's idea of the character class
1965 <blank>, which controls how it splits tokens, when the locale changes.
1966
1967mmm. The shell now binds its special readline functions and key bindings only
1968 if the user's inputrc file has not already bound them.
1969
1970nnn. The shell now reports on processes that dump core due to signals when
1971 invoked as `-c command'.
1972
19732. Changes to Readline
1974
1975a. Fixes to avoid core dumps because of null pointer references in the
1976 multibyte character code.
1977
1978b. Fix to avoid infinite recursion caused by certain key combinations.
1979
1980c. Fixed a bug that caused the vi-mode `last command' to be set incorrectly.
1981
1982d. Readline no longer tries to read ahead more than one line of input, even
1983 when more is available.
1984
1985e. Fixed the code that adjusts the point to not mishandle null wide
1986 characters.
1987
1988f. Fixed a bug in the history expansion `g' modifier that caused it to skip
1989 every other match.
1990
1991g. Fixed a bug that caused the prompt to overwrite previous output when the
1992 output doesn't contain a newline and the locale supports multibyte
1993 characters. This same change fixes the problem of readline redisplay
1994 slowing down dramatically as the line gets longer in multibyte locales.
1995
1996h. History traversal with arrow keys in vi insertion mode causes the cursor
1997 to be placed at the end of the new line, like in emacs mode.
1998
1999i. The locale initialization code does a better job of using the right
2000 precedence and defaulting when checking the appropriate environment
2001 variables.
2002
2003j. Fixed the history word tokenizer to handle <( and >( better when used as
2004 part of bash.
2005
2006k. The overwrite mode code received several bug fixes to improve undo.
2007
2008l. Many speedups to the multibyte character redisplay code.
2009
2010m. The callback character reading interface should not hang waiting to read
2011 keyboard input.
2012
2013n. Fixed a bug with redoing vi-mode `s' command.
2014
2015o. The code that initializes the terminal tracks changes made to the terminal
2016 special characters with stty(1) (or equivalent), so that these changes
2017 are reflected in the readline bindings. New application-callable function
2018 to make it work: rl_tty_unset_default_bindings().
2019
2020p. Fixed a bug that could cause garbage to be inserted in the buffer when
2021 changing character case in vi mode when using a multibyte locale.
2022
2023q. Fixed a bug in the redisplay code that caused problems on systems
2024 supporting multibyte characters when moving between history lines when the
2025 new line has more glyphs but fewer bytes.
2026
2027r. Undo and redo now work better after exiting vi insertion mode.
2028
2029s. Make sure system calls are restarted after a SIGWINCH is received using
2030 SA_RESTART.
2031
2032t. Improvements to the code that displays possible completions when using
2033 multibyte characters.
2034
2035u. Fixed a problem when parsing nested if statements in inputrc files.
2036
2037v. The completer now takes multibyte characters into account when looking for
2038 quoted substrings on which to perform completion.
2039
2040w. The history search functions now perform better bounds checking on the
2041 history list.
2042
20433. New Features in Bash
2044
2045a. ANSI string expansion now implements the \x{hexdigits} escape.
2046
2047b. There is a new loadable `strftime' builtin.
2048
2049c. New variable, COMP_WORDBREAKS, which controls the readline completer's
2050 idea of word break characters.
2051
2052d. The `type' builtin no longer reports on aliases unless alias expansion
2053 will actually be performed.
2054
2055e. HISTCONTROL is now a colon-separated list of values, which permits
2056 more extensibility and backwards compatibility.
2057
2058f. HISTCONTROL may now include the `erasedups' option, which causes all lines
2059 matching a line being added to be removed from the history list.
2060
2061g. `configure' has a new `--enable-multibyte' argument that permits multibyte
2062 character support to be disabled even on systems that support it.
2063
2064h. New variables to support the bash debugger: BASH_ARGC, BASH_ARGV,
2065 BASH_SOURCE, BASH_LINENO, BASH_SUBSHELL, BASH_EXECUTION_STRING,
2066 BASH_COMMAND
2067
2068i. FUNCNAME has been changed to support the debugger: it's now an array
2069 variable.
2070
2071j. for, case, select, arithmetic commands now keep line number information
2072 for the debugger.
2073
2074k. There is a new `RETURN' trap executed when a function or sourced script
2075 returns (not inherited child processes; inherited by command substitution
2076 if function tracing is enabled and the debugger is active).
2077
2078l. New invocation option: --debugger. Enables debugging and turns on new
2079 `extdebug' shell option.
2080
2081m. New `functrace' and `errtrace' options to `set -o' cause DEBUG and ERR
2082 traps, respectively, to be inherited by shell functions. Equivalent to
2083 `set -T' and `set -E' respectively. The `functrace' option also controls
2084 whether or not the DEBUG trap is inherited by sourced scripts.
2085
2086n. The DEBUG trap is run before binding the variable and running the action
2087 list in a `for' command, binding the selection variable and running the
2088 query in a `select' command, and before attempting a match in a `case'
2089 command.
2090
2091o. New `--enable-debugger' option to `configure' to compile in the debugger
2092 support code.
2093
2094p. `declare -F' now prints out extra line number and source file information
2095 if the `extdebug' option is set.
2096
2097q. If `extdebug' is enabled, a non-zero return value from a DEBUG trap causes
2098 the next command to be skipped, and a return value of 2 while in a
2099 function or sourced script forces a `return'.
2100
2101r. New `caller' builtin to provide a call stack for the bash debugger.
2102
2103s. The DEBUG trap is run just before the first command in a function body is
2104 executed, for the debugger.
2105
2106t. `for', `select', and `case' command heads are printed when `set -x' is
2107 enabled.
2108
2109u. There is a new {x..y} brace expansion, which is shorthand for {x.x+1,
2110 x+2,...,y}. x and y can be integers or single characters; the sequence
2111 may ascend or descend; the increment is always 1.
2112
2113v. New ksh93-like ${!array[@]} expansion, expands to all the keys (indices)
2114 of array.
2115
2116w. New `force_fignore' shopt option; if enabled, suffixes specified by
2117 FIGNORE cause words to be ignored when performing word completion even
2118 if they're the only possibilities.
2119
2120x. New `gnu_errfmt' shopt option; if enabled, error messages follow the `gnu
2121 style' (filename:lineno:message) format.
2122
2123y. New `-o bashdefault' option to complete and compgen; if set, causes the
2124 whole set of bash completions to be performed if the compspec doesn't
2125 result in a match.
2126
2127z. New `-o plusdirs' option to complete and compgen; if set, causes directory
2128 name completion to be performed and the results added to the rest of the
2129 possible completions.
2130
2131aa. `kill' is available as a builtin even when the shell is built without
2132 job control.
2133
2134bb. New HISTTIMEFORMAT variable; value is a format string to pass to
2135 strftime(3). If set and not null, the `history' builtin prints out
2136 timestamp information according to the specified format when displaying
2137 history entries. If set, bash tells the history library to write out
2138 timestamp information when the history file is written.
2139
2140cc. The [[ ... ]] command has a new binary `=~' operator that performs
2141 extended regular expression (egrep-like) matching.
2142
2143dd. `configure' has a new `--enable-cond-regexp' option (enabled by default)
2144 to enable the =~ operator and regexp matching in [[ ... ]].
2145
2146ee. Subexpressions matched by the =~ operator are placed in the new
2147 BASH_REMATCH array variable.
2148
2149ff. New `failglob' option that causes an expansion error when pathname
2150 expansion fails to produce a match.
2151
2152gg. New `set -o pipefail' option that causes a pipeline to return a failure
2153 status if any of the processes in the pipeline fail, not just the last
2154 one.
2155
21564. New Features in Readline
2157
2158a. History expansion has a new `a' modifier equivalent to the `g' modifier
2159 for compatibility with the BSD csh.
2160
2161b. History expansion has a new `G' modifier equivalent to the BSD csh `g'
2162 modifier, which performs a substitution once per word.
2163
2164c. All non-incremental search operations may now undo the operation of
2165 replacing the current line with the history line.
2166
2167d. The text inserted by an `a' command in vi mode can be reinserted with
2168 `.'.
2169
2170e. New bindable variable, `show-all-if-unmodified'. If set, the readline
2171 completer will list possible completions immediately if there is more
2172 than one completion and partial completion cannot be performed.
2173
2174f. There is a new application-callable `free_history_entry()' function.
2175
2176g. History list entries now contain timestamp information; the history file
2177 functions know how to read and write timestamp information associated
2178 with each entry.
2179
2180h. Four new key binding functions have been added:
2181
2182 rl_bind_key_if_unbound()
2183 rl_bind_key_if_unbound_in_map()
2184 rl_bind_keyseq_if_unbound()
2185 rl_bind_keyseq_if_unbound_in_map()
2186
2187------------------------------------------------------------------------------
7117c2d2
JA
2188This document details the changes between this version, bash-2.05b-release,
2189and the previous version, bash-2.05b-beta2.
2190
21911. Changes to Bash
2192
2193a. Fixed an off-by-one error in the function that translates job
2194 specifications.
2195
2196b. Note that we're running under Emacs and disable line editing if
2197 $EMACS == `t'.
2198
2199------------------------------------------------------------------------------
2200This document details the changes between this version, bash-2.05b-beta2,
2201and the previous version, bash-2.05b-beta1.
2202
22031. Changes to Bash
2204
2205a. Fixed the /= and %= arithmetic operators to catch division by zero.
2206
2207b. Added putenv, setenv, unsetenv to getenv replacement for completeness.
2208
2209c. Fixed a bug that could cause the -O expand_aliases invocation option
2210 to not take effect.
2211
2212d. Fixed a problem with process substitution that resulted in incorrect
2213 behavior when the number of process substitutions in an individual
2214 command approached 64.
2215
22162. Changes to Readline
2217
2218a. Fixed a problem with backward-char-search when on a system with support
2219 for multibyte characters when running in a locale without any multibyte
2220 characters.
2221
2222------------------------------------------------------------------------------
2223This document details the changes between this version, bash-2.05b-beta1,
2224and the previous version, bash-2.05b-alpha1.
2225
22261. Changes to Bash
2227
2228a. Fixed a problem when parsing a POSIX.2 character class name while
2229 evaluating a bracket expression containing multibyte characters.
2230
2231b. Changed the help text for `bind' to make it clear that any command
2232 that may be placed in ~/.inputrc is a valid argument to `bind'.
2233
2234c. Added `help' builtin entries for `((', `[[', and arithmetic for.
2235
2236d. malloc updated again:
2237 o slightly better overflow and underflow detection by putting the
2238 chunk size at the beginning and end of the chunk and making
2239 sure they match in free/realloc
2240 o partial page allocated to make things page-aligned no longer
2241 completely wasted
2242 o block coalescing now enabled by default
2243 o splitting and coalescing enabled for 32-byte chunks, the most
2244 common size requested
2245 o fixed a problem that resulted in spurious underflow messages and
2246 aborts
2247 o bin sizes are precomputed and stored in an array rather than
2248 being computed at run time
2249 o malloc will return memory blocks back to the system if the block
2250 being freed is at the top of the heap and of sufficient size to
2251 make it worthwhile
2252 o malloc/free/realloc now inline memset instead of calling the
2253 libc function; uses Duff's device for good performance
2254
2255e. Check for getservent(); make the service name completion code dependent
2256 on its presence.
2257
2258f. Changed the readline callback that executes a command bound to a key
2259 sequence to not save the executed command on the history list and to
2260 save and restore the parsing state.
2261
2262g. Changes to lib/sh/snprintf.c: fixed some bugs in the `g' and `G'
2263 floating point format display; implemented the "'" flag character
2264 that turns on thousands' grouping; fixed behavior on systems where
2265 MB_CUR_MAX does not evaluate to a constant.
2266
2267h. The `unset' builtin no longer returns a failure status when asked to
2268 unset a previously-unset variable or function.
2269
2270i. Changes to the build system to make it easier to cross-compile bash
2271 for different systems.
2272
2273j. Added `,' to the characters that are backslash-escaped during filename
2274 completion, to avoid problems with complete-into-braces and RCS filenames
2275 containing commas.
2276
2277k. Some changes to the multibyte character support code to avoid many calls
2278 to strlen().
2279
2280l. Bash now correctly honors setting LANG to some value when LC_ALL does not
2281 already have a value.
2282
2283m. Fixed a bug that could cause SIGSEGV when processing nested traps with
2284 trap handlers.
2285
2286n. The `source/.' builtin now restores the positional parameters when it
2287 returns unless they were changed using the `set' builtin during the file's
2288 execution.
2289
2290o. Fixed a bug that caused a syntax error when a command was terminated by
2291 EOF.
2292
22932. New Features in Bash
2294
2295a. There is now support for placing the long help text into separate files
2296 installed into ${datadir}/bash. Not enabled by default; can be turned
2297 on with `--enable-separate-helpfiles' option to configure.
2298
2299b. All builtins that take operands accept a `--' pseudo-option, except
2300 `echo'.
2301
2302c. The `echo' builtin now accepts \0xxx (zero to three octal digits following
2303 the `0') in addition to \xxx (one to three octal digits) for SUSv3/XPG6/
2304 POSIX.1-2001 compliance.
2305
23063. Changes to Readline
2307
2308a. Fixed a small problem in _rl_insert_char with multibyte characters.
2309
2310b. Fixes from IBM for line wrapping problems when using multibyte characters.
2311
2312c. Fixed a problem which caused the display to be messed up when the last
2313 line of a multi-line prompt (possibly containing invisible characters)
2314 was longer than the screen width.
2315
2316d. Fixed a problem with the vi-mode `r' command that ocurred on systems with
2317 support for multibyte characters when running in a locale without any
2318 multibyte characters.
2319
2320------------------------------------------------------------------------------
2321This document details the changes between this version, bash-2.05b-alpha1,
2322and the previous version, bash-2.05a-release.
2323
23241. Changes to Bash
2325
2326a. Some changes to work around inlining differences between compilers.
2327
2328b. Added more prototypes for internal shell typedefs, to catch argument
2329 passing errors when using pointers to functions.
2330
2331c. The `cd' builtin now fails in posix mode when a valid directory cannot be
2332 constructed from a relative pathname argument and the $PWD using pathname
2333 canonicalization, and the -P option has not been supplied. Previously,
2334 the shell would attempt to use what the user typed, leading to weird
2335 values for $PWD and discrepancies between the value of $PWD and the
2336 actual working directory.
2337
2338d. The `cd' builtin now resets $PWD when canonicalization fails but a chdir
2339 to the pathname passed as an argument succeeds (when not in posix mode).
2340
2341e. The `fc' builtin has been fixed, as POSIX requires, to use the closest
2342 history position in range when given an out-of-range argument.
2343
2344f. The history file loading code was changed to allow lines to be saved in
2345 the history list from the shell startup files.
2346
d3a24ed2 2347g. `history -s args' now works better in compound commands.
7117c2d2
JA
2348
2349h. The tilde expansion code was fixed to better recognize when it's being
2350 invoked in an assignment context, which enables expansion after `='
2351 and `:'.
2352
2353i. Fixed the command name completion code so a slash is no longer appended
2354 to a single match if there happens to be a directory with that name in
2355 $PWD.
2356
2357j. Fixed compound array assignment to no longer perform alias expansion, to
2358 allow reserved words as array members, and to not produce extra output
2359 when the `-v' option had been enabled.
2360
2361k. Fixed the programmable completion code to better handle newlines in lists
2362 of possible completions (e.g., `complete -W').
2363
2364l. Removed the reserved words from the `bash-builtins' manual page.
2365
2366m. Parser error reporting now attempts to do a better job of identifying the
2367 token in error rather than doing straight textual analysis.
2368
2369n. Fixes for Inf/NaN, locales, wide/multibyte characters and zero-length
2370 arguments in the library snprintf(3) replacement.
2371
2372o. `read -e' no longer does command name completion on the first word on
2373 the line being read.
2374
2375p. `select' now returns failure if the read of the user's selection fails.
2376
2377q. Fixed a bug that could cause a core dump when setting $PIPESTATUS.
2378
2379r. Fixes to not allocate so many job slots when the shell is running a loop
2380 with job control enabled in a subshell of an interactive shell.
2381
2382s. Fixed a bug in the trap code that caused traps to be inherited by
2383 command substitutions in some cases.
2384
2385t. Fixed a bug that could cause alias expansion to inappropriately expand
2386 the word following the alias.
2387
2388u. Fixed a bug in the `kill' builtin that mishandled negative pid arguments.
2389
2390v. The parser is less lenient when parsing assignment statements where the
2391 characters before the `=' don't comprise a valid identifier.
2392
2393w. The arithmetic expression evaluation code now honors the setting of the
2394 `-u' option when expanding variable names.
2395
2396x. Fixed the arithmetic evaluation code to allow array subscripts to be
2397 assigned (`let b[7]=42') and auto-incremented and auto-decremented
2398 (e.g., b[7]++).
2399
2400y. Reimplemented the existing prompt string date and time expansions using
2401 strftime(3), which changed the output of \@ in some locales.
2402
2403z. Fixed a bug that could cause a core dump when a special shell variable
2404 (like RANDOM) was converted to an array with a variable assignment.
2405
2406aa. Fixed a bug that would reset the handler for a signal the user had
2407 trapped to a function that would exit the shell when setting the exit
2408 trap in a non-interactive shell.
2409
2410bb. Changed the execve(2) wrapper code to check whether or not a failing
2411 command is a directory before looking at whether a `#!' interpreter
2412 failed for some reason.
2413
2414cc. Fixed a bug in the command printing code so it no longer inserts a `;'
2415 after a newline, which produces a syntax error when reused as input.
2416
2417dd. The code that expands $PS4 no longer inherits the `-x' flag.
2418
2419ee. The bash-specific completion functions may now take advantage of the
2420 double-TAB and M-? features of the standard readline completion
2421 functions.
2422
2423ff. The mail checking code no longer prints a message if the checked file's
2424 size has not increased, even if the access time is less than the modification time.
2425
2426gg. Rewrote the variable symbol table code: there is now a stack of
2427 contexts, each possibly including a separate symbol table; there can
2428 be more than one temporary environment supplied to nested invocations
2429 of `./source'; the temporary environments no longer require so much
2430 special-case code; shell functions now handle the temporary environment
2431 and local variables more consistently; function scope exit is faster now
2432 that the entire symbol table does not have to be traversed to dispose of
2433 local variables; it is now easier to push vars from the temporary
2434 environment to the shell's variable table in posix mode; some duplicated
2435 code has been removed.
2436
2437hh. Regularized the error message printing code; builtin_error is now called
2438 more consistently, and common error message strings are handled by small
2439 functions. This should make eventual message translation easier.
2440
2441ii. Error messages now include the line number in a script when the shell
2442 is not interactive.
2443
2444jj. Array subscript expansion now takes place even when the array variable is
2445 unset, so side effects will take place.
2446
2447kk. Fixed a bug in the SICGHLD child-reaping code so that it won't find
2448 jobs already marked as terminated if the OS reuses pids quickly enough.
2449
2450ll. Fixed a bug that could cause a signal to not interrupt the `wait'
2451 builtin while it was waiting for a background process to terminate.
2452
2453mm. A couple of changes to make it easier for multiple shells to share history
2454 files using `history -n', `history -r', and `history -w'.
2455
2456nn. The `getopts' builtin always increments OPTIND to point to the next
2457 option to be handled when an option is returned, whether it's valid
2458 or not, as POSIX 1003.x-2001 requires.
2459
2460oo. Changed some parts of the expansion code to avoid allocating and
2461 immediately freeing memory without using the results for anything.
2462
2463pp. The shell now keeps track of $IFS internally, updating its internal map
2464 each time the variable is assigned a new value (or at local scope exit).
2465 This saves thousands of hash lookups for IFS, which, while individually
2466 cheap, add up.
2467
2468qq. Rewrote the hash table code: searching and insertion are much faster now,
2469 and it uses a better string hashing function; augmented the function
2470 interface to simplify other parts of the code and remove duplicated code
2471
2472rr. The shell now uses a simple, generic `object cache' for allocating and
2473 caching words and word lists, which were the major users of
2474 malloc/free.
2475
2476ss. Fixed the assignment statement parsing code to allow whitespace and
2477 newlines in subscripts when performing array element assignment.
2478
2479tt. The shell now issues many fewer calls to sigprocmask and other signal
2480 masking system calls.
2481
2482uu. Fixed the `test' and conditional command file comparison operators to
2483 work right when one file has a non-positive timestamp and the other
2484 does not exist.
2485
2486vv. Fixed some cases where the special characters '\001' and '\177' in the
2487 values of variables or positional parameters caused incorrect expansion
2488 results.
2489
24902. Changes to Readline
2491
2492a. Fixed output of comment-begin character when listing variable values.
2493
2494b. Added some default key bindings for common escape sequences produced by
2495 HOME and END keys.
2496
2497c. Fixed the mark handling code to be more emacs-compatible.
2498
2499d. A bug was fixed in the code that prints possible completions to keep it
2500 from printing empty strings in certain circumstances.
2501
2502e. Change the key sequence printing code to print ESC as M\- if ESC is a
2503 meta-prefix character -- it's easier for users to understand than \e.
2504
2505f. Fixed unstifle_history() to return values that match the documentation.
2506
2507g. Fixed the event loop (rl_event_hook) to handle the case where the input
2508 file descriptor is invalidated.
2509
2510h. Fixed the prompt display code to work better when the application has a
2511 custom redisplay function.
2512
2513i. Changes to make reading and writing the history file a little faster, and
2514 to cope with huge history files without calling abort(3) from xmalloc.
2515
2516j. The vi-mode `S' and `s' commands are now undone correctly.
2517
25183. New Features in Bash
2519
2520a. If set, TMOUT is the default timeout for the `read' builtin.
2521
2522b. `type' has two new options: `-f' suppresses shell function lookup, and
2523 `-P' forces a $PATH search.
2524
2525c. New code to handle multibyte characters.
2526
2527d. `select' was changed to be more ksh-compatible, in that the menu is
2528 reprinted each time through the loop only if REPLY is set to NULL.
2529 The previous behavior is available as a compile-time option.
2530
2531e. `complete -d' and `complete -o dirnames' now force a slash to be
2532 appended to names which are symlinks to directories.
2533
2534f. There is now a bindable edit-and-execute-command readline command,
2535 like the vi-mode `v' command, bound to C-xC-e in emacs mode.
2536
2537g. Added support for ksh93-like [:word:] character class in pattern matching.
2538
2539h. The $'...' quoting construct now expands \cX to Control-X.
2540
2541i. A new \D{...} prompt expansion; passes the `...' to strftime and inserts
2542 the result into the expanded prompt.
2543
2544j. The shell now performs arithmetic in the largest integer size the
2545 machine supports (intmax_t), instead of long.
2546
2547k. If a numeric argument is supplied to one of the bash globbing completion
2548 functions, a `*' is appended to the word before expansion is attempted.
2549
2550l. The bash globbing completion functions now allow completions to be listed
2551 with double tabs or if `show-all-if-ambiguous' is set.
2552
2553m. New `-o nospace' option for `complete' and `compgen' builtins; suppresses
2554 readline's appending a space to the completed word.
2555
2556n. New `here-string' redirection operator: <<< word.
2557
2558o. When displaying variables, function attributes and definitions are shown
2559 separately, allowing them to be re-used as input (attempting to re-use
2560 the old output would result in syntax errors).
2561
2562p. There is a new configuration option `--enable-mem-scramble', controls
2563 bash malloc behavior of writing garbage characters into memory at
2564 allocation and free time.
2565
2566q. The `complete' and `compgen' builtins now have a new `-s/-A service'
2567 option to complete on names from /etc/services.
2568
2569r. `read' has a new `-u fd' option to read from a specified file descriptor.
2570
2571s. Fix the completion code so that expansion errors in a directory name
2572 don't cause a longjmp back to the command loop.
2573
2574t. Fixed word completion inside command substitution to work a little more
2575 intuitively.
2576
2577u. The `printf' %q format specifier now uses $'...' quoting to print the
2578 argument if it contains non-printing characters.
2579
2580v. The `declare' and `typeset' builtins have a new `-t' option. When applied
2581 to functions, it causes the DEBUG trap to be inherited by the named
2582 function. Currently has no effect on variables.
2583
2584w. The DEBUG trap is now run *before* simple commands, ((...)) commands,
2585 [[...]] conditional commands, and for ((...)) loops.
2586
2587x. The expansion of $LINENO inside a shell function is only relative to the
2588 function start if the shell is interactive -- if the shell is running a
2589 script, $LINENO expands to the line number in the script. This is as
2590 POSIX-2001 requires.
2591
2592y. The bash debugger in examples/bashdb has been modified to work with the
2593 new DEBUG trap semantics, the command set has been made more gdb-like,
2594 and the changes to $LINENO make debugging functions work better. Code
2595 from Gary Vaughan.
2596
2597z. New [n]<&word- and [n]>&word- redirections from ksh93 -- move fds (dup
2598 and close).
2599
2600aa. There is a new `-l' invocation option, equivalent to `--login'.
2601
2602bb. The `hash' builtin has a new `-l' option to list contents in a reusable
2603 format, and a `-d' option to remove a name from the hash table.
2604
26054. New Features in Readline
2606
2607a. Support for key `subsequences': allows, e.g., ESC and ESC-a to both
2608 be bound to readline functions. Now the arrow keys may be used in vi
2609 insert mode.
2610
2611b. When listing completions, and the number of lines displayed is more than
2612 the screen length, readline uses an internal pager to display the results.
2613 This is controlled by the `page-completions' variable (default on).
2614
2615c. New code to handle editing and displaying multibyte characters.
2616
2617d. The behavior introduced in bash-2.05a of deciding whether or not to
2618 append a slash to a completed name that is a symlink to a directory has
2619 been made optional, controlled by the `mark-symlinked-directories'
2620 variable (default is the 2.05a behavior).
2621
2622e. The `insert-comment' command now acts as a toggle if given a numeric
2623 argument: if the first characters on the line don't specify a
2624 comment, insert one; if they do, delete the comment text
2625
2626f. New application-settable completion variable:
2627 rl_completion_mark_symlink_dirs, allows an application's completion
2628 function to temporarily override the user's preference for appending
2629 slashes to names which are symlinks to directories.
2630
2631g. New function available to application completion functions:
2632 rl_completion_mode, to tell how the completion function was invoked
2633 and decide which argument to supply to rl_complete_internal (to list
2634 completions, etc.).
2635
2636h. Readline now has an overwrite mode, toggled by the `overwrite-mode'
2637 bindable command, which could be bound to `Insert'.
2638
2639i. New application-settable completion variable:
2640 rl_completion_suppress_append, inhibits appending of
2641 rl_completion_append_character to completed words.
2642
2643j. New key bindings when reading an incremental search string: ^W yanks
2644 the currently-matched word out of the current line into the search
2645 string; ^Y yanks the rest of the current line into the search string,
2646 DEL or ^H deletes characters from the search string.
2647
2648------------------------------------------------------------------------------
f73dda09
JA
2649This document details the changes between this version, bash-2.05a-release,
2650and the previous version, bash-2.05a-rc1.
2651
26521. Changes to Bash
2653
2654a. Fixed the `printf' builtin so that the variable name supplied as an
2655 argument to a %n conversion must be a valid shell identifier.
2656
2657b. Improved the random number generator slightly.
2658
2659c. Changes to configuration to not put -I/usr/include into $CFLAGS, since
2660 it messes up some includes.
2661
2662d. Corrected description of POSIXLY_CORRECT in man page and info manual.
2663
2664e. Fixed a couple of cases of incorrect function prototypes that sneaked
2665 through and caused compilation problems.
2666
2667f. A few changes to avoid potential core dumps in the programmable completion
2668 code.
2669
2670g. Fixed a configure problem that could cause a non-existent file to show
2671 up in LIBOBJS.
2672
2673h. Fixed a configure problem that could cause siglist.o to not be built when
2674 required.
2675
2676i. Changes to the strtoimax and strtoumax replacement functions to work
2677 around buggy compilers.
2678
2679j. Fixed a problem with the snprintf replacement function that could
2680 potentially cause a core dump.
2681
26822. Changes to Readline
2683
2684a. Fixed a locale-specific problem in the vi-mode `goto mark' command.
2685
2686b. Fixed Makefile to not put -I/usr/include into CFLAGS, since it can cause
2687 include file problems.
2688
2689------------------------------------------------------------------------------
2690This document details the changes between this version, bash-2.05a-rc1,
2691and the previous version, bash-2.05a-beta1.
2692
26931. Changes to Bash
2694
2695a. Fixed the snprintf replacement to correctly implement the `alternate form'
2696 of the %g and %G conversions.
2697
2698b. Fixed snprintf to correctly handle the optional precision with the %g and
2699 %G conversions.
2700
2701c. Fixed the arithmetic evaluation code to correct the values of `@' and `_'
2702 when translating base-64 constants (they were backwards).
2703
2704d. New library functions for formatting long and long long ints.
2705
2706e. Fixed a few places where negative array subscripts could have occurred,
2707 mostly as the result of systems using signed characters.
2708
2709f. Fixed a few places that assumed a pid_t was no wider than an int.
2710
2711g. Fixed the `maildir' mail checking code to work on systems where a
2712 `struct stat' doesn't include an `st_blocks' member.
2713
2714h. Fixed snprintf to make `unsigned long long' conversion formats (%llu)
2715 work better.
2716
2717i. Fixed snprintf to not print a sign when asked to do an unsigned conversion.
2718
2719j. Made configure changes to avoid compiling empty source files in lib/sh.
2720
2721k. New replacement functions (if necessary) for strtoull, strtoll, strtoimax,
2722 strtoumax.
2723
2724l. The `printf' builtin now handles the `ll' and `j' length modifiers
2725 directly, since they can affect the type and width of the argument
2726 passed to printf(3).
2727
2728m. Renamed a number of the bash-specific autoconf macros in aclocal.m4 to
2729 have more sytematic naming, with accompanying changes to configure.in.
2730
2731n. Fixed snprintf to handle long doubles and the %a/%A conversions by
2732 falling back to sprintf, as long as sprintf supports them.
2733
2734o. Fixed return value from vsnprintf/snprintf to be the number of characters
2735 that would have been printed, even if that number exceeds the buffer
2736 size passed as an argument.
2737
2738p. Bash no longer attempts to define its own versions of some ctype macros
2739 if they are implemented as functions in libc but not as macros in
2740 <ctype.h>.
2741
2742q. Changed the variable printing code (used by `set', `export', etc.) to
2743 not use the $'...' syntax when in posix mode, since that caused
2744 interoperability problems with other shells (most notably with autoconf).
2745 When not in posix mode, it uses $'...' if the string to be printed
2746 contains non-printing characters and regular single quotes otherwise.
2747
2748r. snprintf now recognizes the %F conversion.
2749
2750s. Fixed a bug that could cause the wrong status to be returned by a shell
2751 function when the shell is compiled without job control and a null
2752 command containing a command substutition was executed in the function.
2753
2754t. When in posix mode, the default value for MAILCHECK is 600.
2755
2756u. Bash only initializes FUNCNAME, GROUPS, and DIRSTACK as special variables
2757 if they're not in the initial environment.
2758
2759v. If SECONDS appears in the initial environment with a valid integer value,
2760 bash uses that as the starting value, as if an assignment had been
2761 performed.
2762
2763w. Bash no longer auto-exports HOME, PATH, SHELL, or TERM, even though it
2764 gives them default values if they don't appear in the initial environment.
2765
2766x. Bash no longer auto-exports HOSTNAME, HOSTTYPE, MACHTYPE, or OSTYPE,
2767 even if it assigns them default values.
2768
2769y. Bash no longer removes the export attribute from SSH_CLIENT or SSH2_CLIENT
2770 if they appear in the initial environment.
2771
2772z. Bash no longer attempts to discover if it's being run by sshd in order to
2773 run the startup files. If the SSH_SOURCE_BASHRC is uncommented in
2774 config-top.h it will attempt to do so as previously, but that's commented
2775 out in the distributed version.
2776
2777aa. Fixed a typo in the code that tests for LC_NUMERIC.
2778
2779bb. The POSIXLY_CORRECT shell variable and its effects are now documented.
2780
2781cc. Some changes to several of the support shell scripts included in the
2782 definitions to try to avoid race conditions and attacks.
2783
2784dd. Several changes to avoid warnings from `gcc -Wall'.
2785
2786ee. Fixed a problem with the `unset' builtin that could cause incorrect
2787 results if asked to unset a variable and an array subscript in the
2788 same command.
2789
2790ff. A few changes to the shell's temporary file creation code to avoid
2791 potential file descriptor leaks and to prefer the system's idea of
2792 the temporary directory to use.
2793
2794gg. Fixes to build with the C alloca in lib/malloc/alloca.c if the system
2795 requires it but the shell has been configured --without-bash-malloc.
2796
2797hh. Updated the documentation to note that only interactive shells resend
2798 SIGHUP to all jobs before exiting.
2799
2800ii. Fixes to only pass unquoted tilde words to tilde_expand, rather than
2801 rely on tilde_expand or getpwnam(3) to handle the quotes (MacOS 10.x
2802 will remove backslashes in any login name passed to getpwnam(3)).
2803
2804jj. Small change from Paul Eggert to make LINENO right in commands run with
2805 `bash -c'.
2806
28072. New Features in Bash
2808
2809a. The `printf' builtin now handles the %a and %A conversions if they're
2810 implemented by printf(3).
2811
2812b. The `printf' builtin now handles the %F conversion (just about like %f).
2813
2814c. The `printf' builtin now handles the %n conversion like printf(3). The
2815 corresponding argument is the name of a shell variable to which the
2816 value is assigned.
2817
28183. Changes to Readline
2819
2820a. Fixed a few places where negative array subscripts could have occurred.
2821
2822b. Fixed the vi-mode code to use a better method to determine the bounds of
2823 the array used to hold the marks.
2824
2825c. Fixed the defines in chardefs.h to work better when chars are signed.
2826
2827d. Fixed configure.in to use the new names for bash autoconf macros.
2828
2829e. Readline no longer attempts to define its own versions of some ctype
2830 macros if they are implemented as functions in libc but not as macros in
2831 <ctype.h>.
2832
2833f. Fixed a problem where rl_backward could possibly set point to before
2834 the beginning of the line.
2835
2836------------------------------------------------------------------------------
2837This document details the changes between this version, bash-2.05a-beta1,
2838and the previous version, bash-2.05a-alpha1.
2839
28401. Changes to Bash
2841
2842a. Fixed a bug in the evalution of arithmetic `for' statements when the
2843 expanded expression is NULL.
2844
2845b. Fixed an unassigned variable problem in the redirection printing code.
2846
2847c. Added more prototypes to extern function declarations in the header
2848 files and to static function declarations in C source files.
2849
2850d. Make sure called functions have a prototype in scope, to get the arguments
2851 and return values right instead of casting. Removed extern function
2852 declarations from C source files that were already included in header
2853 files.
2854
2855e. Changed some function arguments to use function typedefs in general.h so
2856 the prototypes can be checked. The only use of Function and VFunction
2857 now is for unwind-protects.
2858
2859f. More const changes to function arguments and appropriate variables.
2860
2861g. Changed the mail checking support to handle `maildir'-style mail
2862 directories.
2863
2864h. Augmented the bash malloc to pass in the file and line number information
2865 for each malloc, realloc, and free. This should result in better error
2866 messages.
2867
2868i. The `old' gnu malloc is no longer a configuration option.
2869
2870j. Augmented the bash malloc with optional tracing and registering allocated
2871 and freed memory.
2872
2873k. Prompt string decoding now saves and restores the value of $? when it
2874 expands the prompt string, so command substitutions don't change $?.
2875
2876i. Array indices are now `long', since shell arithmetic is performed as long,
2877 and the internal arrayind_t type is used consistently.
2878
2879j. Some more `unsigned char *' fixes from Paul Eggert.
2880
2881k. Fixed a bad call to builtin_error that could cause core dumps when making
2882 local variables.
2883
2884l. `return' may no longer be used to terminate a `select' command, for
2885 compatibility with ksh.
2886
2887m. Changed code that reads octal numbers to do a better job of detecting
2888 overflows.
2889
2890n. The time formatting code no longer uses absolute indices into a buffer,
2891 because the buffer size changes depending on the size of a `time_t'.
2892
2893o. `umask' now prints four digits when printing in octal mode, for
2894 compatibility with other shells.
2895
2896p. Lots of changes to the `printf' builtin from Paul Eggert: it handles `L'
2897 formats and long doubles better, and internal functions have been
2898 simpified where appropriate.
2899
2900q. Some `time_t' fixes for machines were a time_t is bigger than a long.
2901
2902r. Replaced some bash-specific autoconf macros with standard equivalents.
2903
2904s. Improvmed the code that constructs temporary filenames to make the
2905 generated names a bit more random.
2906
2907t. Added code that checks for ascii before calling any of the is* ctype
2908 functions.
2909
2910u. Changed some places where a `char' was used as an array subscript to use
2911 `unsigned char', since a `char' can be negative if it's signed by default.
2912
2913v. Lots of changes to the `ulimit' builtin from Paul Eggert to add support
2914 for the new POSIX-200x RLIM_SAVED_CUR and RLIM_SAVED_MAX values and
2915 simplify the code.
2916
2917w. `ulimit' now prints the description of a resource in any error message
2918 relating to fetching or setting that resource's limits.
2919
2920x. The `snprintf' replacement now computes maximum values at compile
2921 time rather than using huge constants for things like long long.
2922
2923y. Interactive shells now ignore `set -n'.
2924
2925z. Changed the malloc bookkeeping information so that it's now 8 bytes
2926 instead of 12 on most 32-bit machines (saving 4 bytes per allocation),
2927 restoring 8-byte alignment.
2928
2929aa. The malloc error reporting code now attempts to print the file and line
2930 number of the call that caused the error.
2931
2932bb. Changed the redirection error reporting code to catch EBADF errors and
2933 report the file descriptor number rather than the file being redirected
2934 to or from (e.g., things like `exec 4242<x' where 4242 is an out-of-range
2935 file descriptor).
2936
2937cc. `printf', `echo -e', and the $'...' code now process only two hex digits
2938 after a `\x' escape sequence for compatibility with other shells, and
2939 the documentation was changed to note that the octal and hex escape
2940 sequences result in an eight-bit value rather than strict ASCII.
2941
29422. Changes to Readline
2943
2944a. The completion code now attempts to do a better job of preserving the
2945 case of the word the user typed if ignoring case in completions.
2946
2947b. Readline defaults to not echoing the input and lets the terminal
2948 initialization code enable echoing if there is a controlling terminal.
2949
2950c. The key binding code now processes only two hex digits after a `\x'
2951 escape sequence, and the documentation was changed to note that the
2952 octal and hex escape sequences result in an eight-bit value rather
2953 than strict ASCII.
2954
29553. New Features in Bash
2956
2957a. The builtin `ulimit' now takes two new non-numeric arguments: `hard',
2958 meaning the current hard limit, and `soft', meaning the current soft
2959 limit, in addition to `unlimited'
2960
2961b. `ulimit' now prints the option letter associated with a particular
2962 resource when printing more than one limit.
2963
2964c. `ulimit' prints `hard' or `soft' when a value is not `unlimited' but is
2965 one of RLIM_SAVED_MAX or RLIM_SAVED_CUR, respectively.
2966
29674. New Features in Readline
2968
2969a. New bindable variable `history-preserve-point'. If set, the history
2970 code attempts to place the user at the same location on each history
2971 line retrived with previous-history or next-history.
2972
2973------------------------------------------------------------------------------
2974This document details the changes between this version, bash-2.05a-alpha1,
2975and the previous version, bash-2.05-release.
2976
29771. Changes to Bash
2978
2979a. Better checks in the redirection code for write errors.
2980
2981b. bashbug now uses $TMPDIR, defaulting to /tmp, and uses mktemp(1) more
2982 portably.
2983
2984c. System-specific configuration changes for: Interix, OpenBSD, FreeBSD,
2985 MacOS X.
2986
2987d. Some more `const' cleanups through the code.
2988
2989e. Fixed a typo in the /dev/fd redirection code, better checks for valid
2990 numeric fds in /dev/fd.
2991
2992f. Fixed many parts of the shell to handle integer overflow more gracefully
2993 and to do more stringent checks for valid numbers.
2994
2995g. Fixed mksignames to include config.h.
2996
2997h. Fixed an uninitialized variable problem that could cause the shell to core
2998 dump when replacing characters in a string.
2999
3000i. New mechanism for updating the patch level when official patches are
3001 released (patchlevel.h).
3002
3003j. configure.in changed to no longer require external files _distribution and
3004 _patchlevel.
3005
3006k. Fixed non-interactive shell initialization problem when bash started as
3007 `bash -i filename'.
3008
3009l. Fixed printf builtin conversion error handling to be POSIX.2-conformant.
3010
3011m. autoconf-2.52 is now used to build configure; autoconf-2.50 or newer is
3012 required. Some of the bash-specific macros were removed, since they are
3013 now standard.
3014
3015n. Startup files and files read with source or `.' are no longer required to
3016 be regular files.
3017
3018o. Fixed core dump in builtin printf when user-supplied precision or field
3019 width is 0.
3020
3021p. Fixed builtin printf to treat a negative field width as a positive field
3022 width with left-justification.
3023
3024r. New unwind-protect implementation from Paul Eggert.
3025
3026s. Fixed an inadvertently-unclosed comment in the bash completion code that
3027 caused programmable completions to not add trailing slashes or spaces to
3028 completions.
3029
3030t. Fixed the process substitution code to cope better when stdin is closed.
3031
3032v. Fixes, mostly from Paul Eggert, for a few possible buffer overflows in
3033 the shell.
3034
3035w. Fixes from Paul Eggert to avoid most of the type casts in the shell code,
3036 and use more appropriate types for a number of variables.
3037
3038x. Command substition no longer inherits the DEBUG trap.
3039
3040y. Some fixes to the process substition code on machines without /dev/fd so
3041 that named pipes are not removed inappropriately.
3042
3043z. The loadable `getconf' builtin is now much more complete, and will become
3044 part of the shell in the future.
3045
3046aa. The select command no longer terminates on a `return', so it can be used
3047 to return from an enclosing function (as ksh does it).
3048
3049bb. Fixed the extended pattern matching code to behave better when presented
3050 with incorrectly-formed patterns.
3051
3052cc. Some changes were made with the intent of making cross-compilation easier.
3053
3054dd. The network code (/dev/tcp and /dev/udp redirections) uses getaddrinfo(3)
3055 if it's available, which adds support for IPv6.
3056
3057ee. Subshells of login shells no longer source ~/.bash_logout when they exit.
3058
3059ff. Fixes so that subshells don't exit inappropriately if the -e option has
3060 been set.
3061
3062gg. Restricted shells no longer allow functions to be exported.
3063
3064hh. Changes to the pattern matching code so extended pattern matching works
3065 on systems with deficient shared library implementations, like MacOS X.
3066
3067ii. Better error messages when a script with a leading `#!interp' fails
3068 to execute because of problems with `interp'.
3069
3070jj. Fixed `compgen' to handle the `-o default' option better.
3071
3072kk. Fixed the job control code to force an asynchronous process's standard
3073 input to /dev/null only if job control is not active.
3074
3075ll. Fixed a possible infinite recursion problem when `fc ""=abc' (a null
3076 pattern) is used to re-execute a previous command.
3077
3078mm. Fixed `declare [-a] var=value' to assign VALUE to element 0 if VAR is an
3079 array variable. Similarly for `declare [-a] var[N]=value'. This is like
3080 ksh93.
3081
3082nn. Fixed a bug that caused `read -a aname' to work even if ANAME had been
3083 declared readonly.
3084
3085oo. Fixed a possible integer overflow problem when constructing names for
3086 temporary files.
3087
30882. New Features in Bash
3089
3090a. Added support for DESTDIR installation root prefix, so you can do a
3091 `make install DESTDIR=bash-root' and do easier binary packaging.
3092
3093b. Added support for builtin printf "'" flag character as per latest POSIX
3094 drafts.
3095
3096c. Support for POSIX.2 printf(1) length specifiers `j', `t', and `z' (from
3097 ISO C99).
3098
3099d. New autoconf macro, RL_LIB_READLINE_VERSION, for use by other applications
3100 (bash doesn't use very much of what it returns).
3101
3102e. `set [-+]o nolog' is recognized as required by the latest POSIX drafts,
3103 but ignored.
3104
3105f. New read-only `shopt' option: login_shell. Set to non-zero value if the
3106 shell is a login shell.
3107
3108g. New `\A' prompt string escape sequence; expands to time in 24 HH:MM format.
3109
3110h. New `-A group/-g' option to complete and compgen; does group name
3111 completion.
3112
3113i. New `-t' option to `hash' to list hash values for each filename argument.
3114
3115j. New [-+]O invocation option to set and unset `shopt' options at startup.
3116
3117k. configure's `--with-installed-readline' option now takes an optional
3118 `=PATH' suffix to set the root of the tree where readline is installed
3119 to PATH.
3120
3121l. The ksh-like `ERR' trap has been added. The `ERR' trap will be run
3122 whenever the shell would have exited if the -e option were enabled.
3123 It is not inherited by shell functions.
3124
3125m. `readonly', `export', and `declare' now print variables which have been
3126 given attributes but not set by assigning a value as just a command and
3127 a variable name (like `export foo') when listing, as the latest POSIX
3128 drafts require.
3129
3130n. `bashbug' now requires that the subject be changed from the default.
3131
3132o. configure has a new `--enable-largefile' option, like other GNU utilities.
3133
3134p. `for' loops now allow empty word lists after `in', like the latest POSIX
3135 drafts require.
3136
31373. Changes to Readline
3138
3139a. More `const' and type casting fixes.
3140
3141b. Changed rl_message() to use vsnprintf(3) (if available) to fix buffer
3142 overflow problems.
3143
3144c. The completion code no longer appends a `/' or ` ' to a match when
3145 completing a symbolic link that resolves to a directory name, unless
3146 the match does not add anything to the word being completed. This
3147 means that a tab will complete the word up to the full name, but not
3148 add anything, and a subsequent tab will add a slash.
3149
3150d. Fixed a trivial typo that made the vi-mode `dT' command not work.
3151
3152e. Fixed the tty code so that ^S and ^Q can be inserted with rl_quoted_insert.
3153
3154f. Fixed the tty code so that ^V works more than once.
3155
3156g. Changed the use of __P((...)) for function prototypes to PARAMS((...))
3157 because the use of __P in typedefs conflicted g++ and glibc.
3158
31594. New Features in Readline
3160
3161a. Added extern declaration for rl_get_termcap to readline.h, making it a
3162 public function (it was always there, just not in readline.h).
3163
3164b. New #defines in readline.h: RL_READLINE_VERSION, currently 0x0402,
3165 RL_VERSION_MAJOR, currently 4, and RL_VERSION_MINOR, currently 2.
3166
3167c. New readline variable: rl_readline_version, mirrors RL_READLINE_VERSION.
3168
3169d. New bindable boolean readline variable: match-hidden-files. Controls
3170 completion of files beginning with a `.' (on Unix). Enabled by default.
3171
3172e. The history expansion code now allows any character to terminate a
3173 `:first-' modifier, like csh.
3174
3175f. The incremental search code remembers the last search string and uses
3176 it if ^R^R is typed without a search string.
3177
3178------------------------------------------------------------------------------
28ef6c31
JA
3179This document details the changes between this version, bash-2.05-release,
3180and the previous version, bash-2.05-beta2.
3181
31821. Changes to Bash
3183
3184a. Make sure we note that the first line of a multi-line command was not
3185 saved in the history if the tests for HISTCONTROL succeed, but the
3186 HISTIGNORE check fails.
3187
3188b. Fixed a bug in the pattern matching code that caused `[' to be treated
3189 as a special character inside a `[...]' bracket expression.
3190
3191c. Fixed a bug in the pattern matching code that caused `]' to terminate
3192 a bracket expression even if it was the first character after the `['
3193 (or a leading `!' or `^').
3194
3195d. Made a small change to report a more user-friendly error message if
3196 execve(2) fails because of an error with the interpreter in a script
3197 with a leading `#! interpreter'.
3198
3199e. If the OS does not support an exec(2) magic number of `#!', make sure we
3200 have a non-null interpreter name before attempting to execute it.
3201
3202f. Fixed a bug that caused the shell process to end up in a different
3203 process group than the controlling terminal if a job-control shell was
3204 run with `exec' in the startup files.
3205
3206g. When started in POSIX mode, either by `bash --posix', `bash -o posix', or
3207 `sh', $SHELLOPTS includes `posix' and POSIXLY_CORRECT is set.
3208
3209h. Fixed a problem that caused the `\W' prompt string escape sequence to
3210 expand to nothing when $PWD was `//'.
3211
3212i. The `bashbug' shell script no longer uses $(...) command substitution.
3213
3214j. When `set' is invoked without options in POSIX mode, it no longer prints
3215 the names and definitions of shell functions.
3216
32172. Changes to Readline
3218
3219a. rl_set_paren_blink_timeout() is now documented.
3220
3221b. Corrected history.3 man page: `$' is not in the default value of
3222 history_word_delimiters.
3223
3224c. If a hook function assigned to rl_event_hook sets rl_done to a non-zero
3225 value, rl_read_key() now immediately returns '\n' (which is assumed to
3226 be bound to accept-line).
3227
32283. New Features in Bash
3229
3230a. The `>&word' redirection now works in POSIX mode as it does by default,
3231 since POSIX.2 leaves it unspecified.
3232
3233------------------------------------------------------------------------------
3234This document details the changes between this version, bash-2.05-beta2,
3235and the previous version, bash-2.05-beta1.
3236
32371. Changes to Bash
3238
3239a. Fixed a bug in the arithmetic evaluation code so that a^=b is supported.
3240
3241b. Fixed startup so posixly_correct is retained across subshells begun to
3242 execute scripts without a leading `#!'.
3243
3244c. Fixed a bug that caused $(< file) to not work in a (...) subshell.
3245
3246d. Added config support for Linux running on the IBM S390.
3247
3248e. Fixed a bug that caused bash to get its input pointer out of sync when
3249 reading commands through a pipe and running a command with standard
3250 input redirected from a file.
3251
3252f. Made a change so that command completion now makes about half as many
3253 stat(2) calls when searching the $PATH.
3254
3255g. Fixed a bug that caused variable assignments preceding `return' to not
3256 be propagated to the shell environment in POSIX mode.
3257
3258h. Fixed a bug with ${parameter[:]?word} -- tilde expansion was not performed
3259 on `word'.
3260
3261i. In POSIX mode, `break' and `continue' do not complain and return success
3262 if called when the shell is not executing a loop.
3263
3264j. Fixed `bash -o posix' to work the same as `bash --posix'.
3265
3266k. Fixed a bug where variable assignments preceding `eval' or `source/.'
3267 would not show up in the environment exported to subshells run by the
3268 commands.
3269
3270l. In POSIX mode, shells started to execute command substitutions inherit
3271 the value of the `-e' option from their parent shell.
3272
3273m. In POSIX mode, aliases are expanded even in non-interactive shells.
3274
3275n. Changed some of the job control messages to display the text required by
3276 POSIX.2 when the shell is in POSIX mode.
3277
3278o. Fixed a bug in `test' that caused it to occasionally return incorrect
3279 results when non-numeric arguments were supplied to `-t'.
3280
32812. Changes to Readline
3282
3283a. Some changes were made to avoid gcc warnings with -Wall.
3284
3285b. rl_get_keymap_by_name now finds keymaps case-insensitively, so
3286 `set keymap EMACS' works.
3287
3288c. The history file writing and truncation functions now return a useful
3289 status on error.
3290
3291d. Fixed a bug that could cause applications to dereference a NULL pointer
3292 if a NULL second argument was passed to history_expand().
3293
32943. New Features in Bash
3295
3296a. doc/readline.3 has been moved to the readline distribution.
3297
32984. New Features in Readline
3299
3300a. New function, rl_get_screen_size (int *rows, int *columns), returns
3301 readline's idea of the screen dimensions.
3302
3303b. The timeout in rl_gather_tyi (readline keyboard input polling function)
3304 is now settable via a function (rl_set_keyboard_input_timeout()).
3305
3306c. Renamed the max_input_history variable to history_max_entries; the old
3307 variable is maintained for backwards compatibility.
3308
3309d. The list of characters that separate words for the history tokenizer is
3310 now settable with a variable: history_word_delimiters. The default
3311 value is as before.
3312
3313------------------------------------------------------------------------------
3314This document details the changes between this version, bash-2.05-beta1,
3315and the previous version, bash-2.05-alpha1.
3316
33171. Changes to Bash
3318
3319a. Changes to allow shared library and object building on the GNU Hurd.
3320
3321b. Fixes to the way exported functions are placed into the environment and
3322 cached.
3323
3324c. The globbing library once again respects locales when processing ranges
3325 in bracket expressions while doing pattern matching.
3326
3327d. System-specific configuration changes for: Tru 64, Interix
3328
3329e. Bashbug now uses /usr/bin/editor as one of the editing alternatives, and
3330 will use mktemp(1) or tempfile(1), if present, for temporary file creation.
3331
3332f. Bash no longer performs a binary file check on a script argument that's
3333 really a tty (like /dev/fd/0 or /dev/stdin).
3334
3335g. Fixed a bug in the execution of shell scripts that caused the effects of
3336 $BASH_ENV to be undone in some cases.
3337
3338h. Fixed several bugs that made `bash [-i] /dev/stdin' not work correctly.
3339
3340i. Several changes to the job control code to avoid some signal state
3341 manipulation.
3342
3343j. The Bash malloc no longer blocks signals as often, which should make it
3344 faster.
3345
3346k. Fixed a parsing bug that did not allow backslash to escape a single quote
3347 inside a $'...' construct.
3348
3349l. Fixed a bug that caused things like ${var:=$'value'} to be parsed
3350 incorrectly. This showed up in newer versions of autoconf.
3351
3352m. Fixed a bug in the bash-specific readline initialization that caused
3353 key bindings to bash-specific function names appearing in .inputrc to
3354 not be honored.
3355
3356n. Bash now sets the file descriptor it uses to save the file descriptor
3357 opened on a shell script to close on exec.
3358
3359o. Fixed a bug in the prompt string decoding that caused it to misbehave
3360 when presented an octal sequence of fewer than three characters.
3361
3362p. Fixed the `test' builtin to return an error if `[' is supplied a single
3363 argument that is not `]'.
3364
3365q. Fixed a bug that caused subshells started to run executable shell scripts
3366 without a leading `#!' to incorrectly inherit an argument list preceding
3367 a shell builtin (like such a script called from a script sourced with `.',
3368 where there were variable assignments preceding the `.' command)
3369
3370r. Fixed a bug that caused changes to variables supplied in an assignment
3371 statement preceding a shell builtin to not be honored (like a script
3372 run with `.').
3373
3374s. HOSTTYPE, OSTYPE, and MACHTYPE are set only if they do not have values
3375 when the shell is started.
3376
3377t. Fixed a bug that caused SIGINT to kill shell scripts after the script
3378 called `wait'.
3379
3380u. The `fc' builtin now tries to create its temporary files in the directory
3381 named by $TMPDIR.
3382
3383v. Bash no longer calls any Readline functions or uses any Readline variables
3384 not declared in readline.h.
3385
3386w. Fixed a bug that caused some substitutions involving $@ to not be split
3387 correctly, especially expansions of the form ${paramterOPword}.
3388
3389x. SSH2_CLIENT is now treated like SSH_CLIENT and not auto-exported if it
3390 appears in the initial environment.
3391
3392y. Fixed a couple of problems with shell scripts without a leading `#!'
3393 being executed out of shell functions that could cause core dumps if
3394 such a script attempted to execute `return'.
3395
3396z. Fixed a problem with the `-nt' and `-ot' binary operators for the
3397 `test/[' builtin and the `[[' conditional command that caused wrong
3398 return values if one of the file arguments did not exist.
3399
3400aa. Fixed a bug that caused non-interactive shells which had previously
3401 executed `shopt -s expand_aliases' to fail to expand aliases in a
3402 command like `(command) &'.
3403
34042. Changes to Readline
3405
3406a. Changes to make most (but not yet all -- there is still crlf()) of the
3407 exported readline functions declared in readline.h have an rl_ prefix.
3408
3409b. More `const' changes in function arguments, mostly for completion
3410 functions.
3411
3412c. Fixed a bug in rl_forward that could cause the point to be set to before
3413 the beginning of the line in vi mode.
3414
3415d. Fixed a bug in the callback read-char interface to make it work when a
3416 readline function pushes some input onto the input stream with
3417 rl_execute_next (like the incremental search functions).
3418
3419e. Fixed a file descriptor leak in the history file manipulation code that
3420 was tripped when attempting to truncate a non-regular file (like
3421 /dev/null).
3422
3423f. Some existing variables are now documented and part of the public
3424 interface (declared in readline.h): rl_explict_arg, rl_numeric_arg,
3425 rl_editing_mode, rl_last_func.
3426
3427g. Renamed rltty_set_default_bindings to rl_tty_set_default_bindings and
3428 crlf to rl_crlf, so there are no public functions declared in readline.h
3429 without an `rl_' prefix. The old functions still exist for backwards
3430 compatibility.
3431
34323. New Features in Bash
3433
3434a. A new loadable builtin, realpath, which canonicalizes and expands symlinks
3435 in pathname arguments.
3436
3437b. When `set' is called without options, it prints function defintions in a
3438 way that allows them to be reused as input. This affects `declare' and
3439 `declare -p' as well.
3440
34414. New Features in Readline
3442
3443a. New application-callable function rl_set_prompt(const char *prompt):
3444 expands its prompt string argument and sets rl_prompt to the result.
3445
3446b. New application-callable function rl_set_screen_size(int rows, int cols):
3447 public method for applications to set readline's idea of the screen
3448 dimensions.
3449
3450c. The history example program (examples/histexamp.c) is now built as one
3451 of the examples.
3452
3453------------------------------------------------------------------------------
3454This document details the changes between this version, bash-2.05-alpha1,
3455and the previous version, bash-2.04-release.
3456
34571. Changes to Bash
3458
3459a. A fix was made to allow newlines in compond array assignments.
3460
3461b. configure now checks for real-time signals with unusable values.
3462
3463c. Interactive shells no longer exit if a substitution fails because of an
3464 unset variable within a sourced file.
3465
3466d. Fixed a problem with incorrect matching of extended glob patterns when
3467 doing pattern substitution.
3468
3469e. `{' is now quoted by the completion code when it appears in a filename.
3470
3471f. Fixed an error in pattern matching that caused the matcher to not
3472 correctly skip the rest of a bracket expression after a character
3473 matched.
3474
3475g. Fixed a bug in the IFS word splitting code to make a non-whitespace IFS
3476 character preceded by IFS whitespace part of the current delimiter rather
3477 than generating a separate field.
3478
3479h. The {!prefix@} expansion now generates separate words, analogous to $@,
3480 when double-quoted.
3481
3482i. Command substitution now ignores NUL bytes in the command output, and the
3483 parser ignores them on input.
3484
3485j. A fix was made to the job control code to prevent hanging processes when
3486 the shell thinks background processes are running but the kernel returns
3487 -1/ECHILD from waitpid().
3488
3489k. `pwd' now prints an error message if the write fails when displaying the
3490 current directory.
3491
3492l. When in POSIX mode, the shell prints trap dispostions without a leading
3493 `SIG' in the signal specification.
3494
3495m. Fixed a parser bug that caused the current command's line count to be
3496 messed up by a compound array assignment.
3497
3498n. Fixed a bug in the unwind-protect code that caused bad behavior on machines
3499 where ints and pointers are not the same size.
3500
3501o. System-specific configure changes for: MacOS X.
3502
3503p. Changes for Cygwin to translate \r\n and \r to \n and to set file
3504 descriptors used for reading input to text mode in various places.
3505
3506q. Fixed a bug that caused `!' to occasionally not be honored when in
3507 a (...) subshell.
3508
3509r. Bash no longer assumes that getcwd() will return any useful error message
3510 in the buffer passed as an argument if the call fails.
3511
3512s. The `source', `.', and `fc' builtins no longer check whether a file is
3513 binary before reading commands from it.
3514
3515t. Subshells no longer turn off job control when they exit, since that
3516 sometimes resulted in the terminal being reset to the wrong process
3517 group.
3518
3519u. The history code no longer tries to save the second and subsequent lines
3520 of a multi-line command if the first line was not saved.
3521
3522v. The history saving code now does a better job of saving blank lines in a
3523 multi-line command.
3524
3525w. Removed a `feature' that made `ulimit' silently translate `unlimited' to
3526 the current hard limit, which obscured some kernel error returns.
3527
3528x. Fixed the grammar so that `}' is recognized as a reserved word after
3529 another reserved word, rather than requiring a `;' or newline. This
3530 means that constructs like
3531
3532 { { echo a b c ; } }
3533
3534 work as expected.
3535
3536y. Conditional commands ([[...]]) now perform tilde expansion on their
3537 arguments.
3538
3539z. Noted in the documentation that `set -a' will cause functions to be
3540 exported if they are defined after `set -a' is executed.
3541
3542aa. When an interactive login shell starts, if $PWD and $HOME refer to the
3543 same directory but are not the same string, $PWD is set to $HOME.
3544
3545bb. Fixed `printf' to handle invalid floating point numbers better.
3546
3547cc. Temporary files are now created with random filenames, to improve security.
3548
3549dd. The readline initialization code now binds the custom bash functions and
3550 key bindings after the readline defaults are set up.
3551
3552ee. Fixed the `source' builtin to no longer overwrite a shell function's
3553 argument list, even if the sourced file changes the positional parameters.
3554
3555ff. A bug fix was made in the expansion of `$*' in contexts where it should
3556 not be split, like assignment statements.
3557
3558gg. Fixed a bug in the parameter substring expansion to handle conditional
3559 arithmetic expressions ( exp ? val1 : val2 ) without cutting the expression
3560 off at the wrong `:'.
3561
3562hh. The `<>' redirection is no longer subject to the current setting of
3563 `noclobber', as POSIX.2 specifies.
3564
3565ii. Fixed a bug in the conditional command parsing code that caused expressions
3566 in parentheses to occasionally be parsed incorrectly.
3567
3568jj. Fixed a bug in the ((...)) arithmetic command to allow do...done or
3569 {...} to follow the )) without an intervening list terminator.
3570
3571kk. `printf' now treats `\E' the same as `\e' when performing backslash escape
3572 expansion for the `%b' format specifier.
3573
3574ll. When in POSIX mode, the shell no longer searches the current directory for
3575 a file to be sourced with `.' or `source' if `.' is not in $PATH.
3576
3577mm. Interactive comments are no longer turned off when POSIX mode is disabled.
3578
3579nn. The UID, EUID, HOSTNAME variables are not set if they are in the shell's
3580 environment when it starts up.
3581
3582oo. Fixed a bug in the `command' builtin so the effect of a command like
3583 `command exec 4<file' is as if the `command' had been omitted.
3584
3585pp. ${foo[@]} and ${foo[*]} now work as in ksh93 if `foo' is not an array
3586 variable.
3587
3588qq. ${#foo[X]}, where X is 0, @, or *, now work as in ksh93 if `foo' is not
3589 an array variable.
3590
3591rr. The shell's idea of an absolute pathname now takes into account a
3592 possible drive specification on Cygwin and other Windows systems.
3593
3594ss. Fixed a bug which caused incorrect parsing of some multi-character
3595 constructs if they were split across input lines with backslash-newline
3596 line continuation.
3597
3598tt. Fixed a bug that caused restricted shell mode to be set inappropriately
3599 when trying to execute a shell script without a leading `#!'.
3600
3601uu. Shell function definitions no longer require that the body be a group
3602 command ( {...} ), as POSIX.2 requires.
3603
3604vv. The `cd' and `pwd' builtins now process symlinks in pathnames internally
3605 and should require many fewer calls to getcwd().
3606
3607ww. Fixed a bug that caused a pipeline's process group to be set incorrectly
3608 if one of the pipeline elements contained a command substitution.
3609
3610xx. Fixed a bug that caused core dumps when expanding the value of HISTIGNORE.
3611
3612yy. The output of `set' is now quoted using $'...' so invisible characters are
3613 displayed as escape sequences.
3614
3615zz. Fixed the help text for `unset', since PATH and IFS may both be unset.
3616
3617aaa. The shell no longer puts directory names into the command hash table.
3618
3619bbb. Fixed a bug in `read' that caused it to occasionally free memory twice if
3620 it was interrupted after reading a large amount of data.
3621
3622ccc. Assignment statements that attempt to assign values to readonly variables
3623 now cause the command to return an error status.
3624
3625ddd. Fixed a bug that could cause incorrect output if a $(<file) construct was
3626 interrupted.
3627
3628eee. GROUPS and FUNCNAME now return an error status when assignment is
3629 attempted, but may be unset (in which case they lose their special
3630 properties). In all respects except unsetting, they are readonly.
3631
3632fff. The string-to-integer conversion code now ignores trailing whitespace in
3633 the string, even if strtol(3) does not.
3634
3635ggg. The tcsh magic-space function now does a better job of inserting the
3636 space close to where the point was before the history expansion, rather
3637 than just appending it.
3638
3639hhh. Fixed a bug which caused a file sourced from an interactive shell to
3640 fill up the jobs table if it ran lots of jobs.
3641
3642iii. Fixed a bug in the parameter pattern substitution code to avoid infinite
3643 recursion on zero-length matches.
3644
36452. Changes to Readline
3646
3647a. When setting the terminal attributes on systems using `struct termio',
3648 readline waits for output to drain before changing the attributes.
3649
3650b. A fix was made to the history word tokenization code to avoid attempts to
3651 dereference a null pointer.
3652
3653c. Readline now defaults rl_terminal_name to $TERM if the calling application
3654 has left it unset, and tries to initialize with the resultant value.
3655
3656d. Instead of calling (*rl_getc_function)() directly to get input in certain
3657 places, readline now calls rl_read_key() consistently.
3658
3659e. Fixed a bug in the completion code that allowed a backslash to quote a
3660 single quote inside a single-quoted string.
3661
3662f. rl_prompt is no longer assigned directly from the argument to readline(),
3663 but uses memory allocated by readline. This allows constant strings to
3664 be passed to readline without problems arising when the prompt processing
3665 code wants to modify the string.
3666
3667g. Fixed a bug that caused non-interactive history searches to return the
3668 wrong line when performing multiple searches backward for the same string.
3669
3670h. Many variables, function arguments, and function return values are now
3671 declared `const' where appropriate, to improve behavior when linking with
3672 C++ code.
3673
3674i. The control character detection code now works better on systems where
3675 `char' is unsigned by default.
3676
3677j. The vi-mode numeric argument is now capped at 999999, just like emacs mode.
3678
3679k. The Function, CPFunction, CPPFunction, and VFunction typedefs have been
3680 replaced with a set of specific prototyped typedefs, though they are
3681 still in the readline header files for backwards compatibility.
3682
3683m. Nearly all of the (undocumented) internal global variables in the library
3684 now have an _rl_ prefix -- there were a number that did not, like
3685 screenheight, screenwidth, alphabetic, etc.
3686
3687n. The ding() convenience function has been renamed to rl_ding(), though the
3688 old function is still defined for backwards compatibility.
3689
3690o. The completion convenience functions filename_completion_function,
3691 username_completion_function, and completion_matches now have an rl_
3692 prefix, though the old names are still defined for backwards compatibility.
3693
3694p. The functions shared by readline and bash (linkage is satisfied from bash
3695 when compiling with bash, and internally otherwise) now have an sh_ prefix.
3696
3697q. Changed the shared library creation procedure on Linux and BSD/OS 4.x so
3698 that the `soname' contains only the major version number rather than the
3699 major and minor numbers.
3700
3701r. Fixed a redisplay bug that occurred when the prompt spanned more than one
3702 physical line and contained invisible characters.
3703
37043. New Features in Bash
3705
3706a. Added a new `--init-file' invocation argument as a synonym for `--rcfile',
3707 per the new GNU coding standards.
3708
3709b. The /dev/tcp and /dev/udp redirections now accept service names as well as
3710 port numbers.
3711
3712c. `complete' and `compgen' now take a `-o value' option, which controls some
3713 of the aspects of that compspec. Valid values are:
3714
3715 default - perform bash default completion if programmable
3716 completion produces no matches
3717 dirnames - perform directory name completion if programmable
3718 completion produces no matches
3719 filenames - tell readline that the compspec produces filenames,
3720 so it can do things like append slashes to
3721 directory names and suppress trailing spaces
3722
37234. New Features in Readline
3724
3725a. The blink timeout for paren matching is now settable by applications.
3726
3727b. _rl_executing_macro has been renamed to rl_executing_macro, which means
3728 it's now part of the public interface.
3729
3730c. Readline has a new variable, rl_readline_state, which is a bitmap that
3731 encapsulates the current state of the library; intended for use by
3732 callbacks and hook functions.
3733
3734------------------------------------------------------------------------------
bb70624e
JA
3735This document details the changes between this version, bash-2.04-release,
3736and the previous version, bash-2.04-beta5.
3737
37381. Changes to Bash
3739
3740a. Better compile-time and configure-time checks for the necessity of
3741 inet_aton().
3742
3743b. A bug was fixed in the expansion of "${@:-}" when there are positional
3744 parameters.
3745
3746c. A typo was fixed in the output of `complete'.
3747
3748d. The matches generated for a word by the `-W' argument to complete and
3749 compgen are now matched against the word being completed, and only
3750 matches are returned as the result.
3751
3752e. Some fixes were made for systems which do not restart read(2) when a
3753 signal caught by bash is received.
3754
3755f. A bug was fixed which caused the umask to be set to 0 when an invalid
3756 symbolic mode mask was parsed.
3757
3758g. Fixed a bug that could cause a core dump if a SIGCHLD was received while
3759 performing an assignment statement using command substitution.
3760
3761h. Changed the word splitting function for programmable completion so cases
3762 in which the cursor is between words are handled a bit better.
3763
37642. Changes to Readline
3765
3766a. rl_funmap_names() is now documented.
3767
37683. New Features in Bash
3769
3770a. The LC_NUMERIC variable is now treated specially, and used to set the
3771 LC_NUMERIC locale category for number formatting, e.g., when `printf'
3772 displays floating-point numbers.
3773
3774------------------------------------------------------------------------------
3775This document details the changes between this version, bash-2.04-beta5,
3776and the previous version, bash-2.04-beta4.
3777
37781. Changes to Bash
3779
3780a. A couple of changes were made to the Makefiles for easier building on
3781 non-Unix systems.
3782
3783b. Fixed a bug where the current prompt would be set to $PS2 at startup.
3784
3785c. The shell script that tests an already-installed version was changed to
3786 remove the directory it created its test programs in at exit.
3787
3788d. Several changes were made to the code that tokenizes an input line for
3789 the programmable completion code. Shell metacharacters will now appear
3790 as individual words in the word list passed to the completion functions.
3791 Some of the example completion shell functions were changed to understand
3792 redirection operators.
3793
3794e. A bug was fixed that, under obscure circumstances, could confuse the
3795 parser when a shell function was run by the programmable completion code.
3796
3797f. A bug was fixed in the ulimit builtin for systems not using getrlimit().
3798
3799g. The execution code now propagates the correct exit status back to the rest
3800 of the code if the return value of a subshell command was being inverted.
3801 Some new test cases for inverting return values with the `!' reserved
3802 word have been added.
3803
3804h. Negative exponents in the arithmetic evaluation of v**e now return an
3805 evaluation error.
3806
3807i. A bug that caused bash to check the wrong process in a pipeline for
3808 abnormal termination (and consequently resetting the terminal attributes)
3809 was fixed.
3810
3811j. Fixed a bug that caused $PS2 to be displayed after PROMPT_COMMAND was
3812 executed.
3813
38142. Changes to Readline
3815
38161. Fixed a bug in a C preprocessor define that caused the keypad control
3817 functions to be compiled out for all platforms except DJGPP.
3818
3819------------------------------------------------------------------------------
3820This document details the changes between this version, bash-2.04-beta4,
3821and the previous version, bash-2.04-beta3.
3822
38231. Changes to Bash
3824
3825a. A couple of changes were made to the redirection to attempt to avoid
3826 race conditions and malicious file replacement.
3827
38282. A change was made to the string evaluation code (used for command
3829 substitution, `eval', and the `.' builtin) to fix an obscure core
3830 dump on alpha machines.
3831
38323. A bug that caused $LINENO to be wrong when executing arithmetic for
3833 commands was fixed.
3834
38354. A couple of memory leaks in the programmable completion code were fixed.
3836
38375. A bug that could cause a core dump by freeing memory twice during a call
3838 to `eval' if `set -u' had been enabled and an undefined variable was
3839 referenced was fixed.
3840
3841------------------------------------------------------------------------------
3842This document details the changes between this version, bash-2.04-beta3,
3843and the previous version, bash-2.04-beta2.
3844
38451. Changes to Bash
3846
3847a. Bash should run the appropriate startup files when invoked by ssh2.
3848
3849b. Fixed a bug in the parsing of conditional commands that could cause a
3850 core dump.
3851
3852c. Fixed a bug in parsing job specifications that occasionally caused
3853 core dumps when an out-of-range job was referenced.
3854
3855d. Fixed the `type' and `command' builtins to do better reporting of
3856 commands that are not found in $PATH or the hash table.
3857
3858e. Fixed a POSIX.2 compliance problem in the command builtin -- commands
3859 are supposed to be reported as full pathnames.
3860
3861f. The `echo' builtin now returns failure if a write error occurs.
3862
3863g. Fixed a bug which caused the locale to not be reset correctly when
3864 LC_ALL was unset.
3865
3866h. Changed description of `getopts' in man page and reference manual to make
3867 it clear that option characters may be characters other than letters.
3868
3869i. If the shell exits while in a function, make sure that any trap on EXIT
3870 doesn't think the function is still executing.
3871
3872j. Bashbug now tries harder to find a usable editor if $EDITOR is not set,
3873 rather than simply defaulting to `emacs'.
3874
3875k. Changes to the scripts that guess and canonicalize the system type, from
3876 the latest `automake' distribution via Debian.
3877
3878l. When using named pipes for process substitution, make sure the file
3879 descriptors opened for reading are set to non-blocking mode.
3880
3881m. Fixed a bug that caused termination of pipelines that are killed by a
3882 signal to not be reported in some cases.
3883
3884n. When not in literal-history mode, shell comment lines are not added to
3885 the history list.
3886
3887o. When running in POSIX.2 mode, bash no longer performs word splitting on
3888 the expanded value of the word supplied as the filename argument to
3889 redirection operators.
3890
3891p. The prompt string decoding code now backslash-quotes only characters that
3892 are special within double quotes when expanding the \w and \W escape
3893 sequences.
3894
3895q. Fixed a bug in the prompt decoding code that could cause a non-interactive
3896 shell to seg fault if `\u' was used in PS4 and the shell was in xtrace
3897 mode.
3898
3899r. Fixed a bug that caused function definitions to be printed with any
3900 redirections that should be attached to the entire function before the
3901 closing brace.
3902
3903s. Changed the tilde expansion code for Cygwin systems to avoid creating
3904 pathnames beginning with `//' if $HOME == `/'.
3905
3906t. Fixed a couple of autoconf tests to avoid creating files with fixed names
3907 in /tmp.
3908
3909u. The `trap' and `kill' builtins now know the names of the POSIX.1b real-
3910 time signals on systems which support them.
3911
39122. Changes to Readline
3913
3914a. Fixed a problem with the single-quote quoting function that could cause
3915 buffer overflows.
3916
3917b. Fixed a bug that caused incorrect `stat characters' to be printed if
3918 the files being completed were in the root directory and visible-stats
3919 was enabled.
3920
39213. New Features in Bash
3922
3923a. There is a new `rbash.1' manual page, from the Debian release.
3924
3925b. The `--enable-usg-echo-default' option to `configure' has been renamed to
3926 `--enable-xpg-echo-default'. The old option is still there for backwards
3927 compatibility.
3928
3929------------------------------------------------------------------------------
3930This document details the changes between this version, bash-2.04-beta2,
3931and the previous version, bash-2.04-beta1.
3932
39331. Changes to Bash
3934
3935a. Fixed a bug that could cause pipes to be closed inappropriately in
3936 some obscure cases.
3937
3938b. Fixed a bug that caused creation of the exported environment to clobber
3939 the current command string if there were any exported shell functions.
3940
3941c. Some changes were made to reduce bash's memory usage.
3942
3943d. Fixed a problem with programmable completion and filenames to be
3944 completed containing quote characters.
3945
3946e. Changed the code the removes named pipes created for the <(...) and >(...)
3947 expansions to defer removal until after any current shell function has
3948 finished executing.
3949
3950f. Fixed a bug in `select' which caused it to not handle the `continue'
3951 builtin correctly.
3952
3953g. Autoconf tests added for cygwin32 and mingw32.
3954
39552. New Features in Bash
3956
3957a. The `--with-bash-malloc' configure option replaces `--with-gnu-malloc'
3958 (which is still there for backwards compatibility).
3959
3960------------------------------------------------------------------------------
3961This document details the changes between this version, bash-2.04-beta1,
3962and the previous version, bash-2.04-alpha1.
3963
39641. Changes to Bash
3965
3966a. Fixed a bug in the programmable completion code that occurred when
3967 trying to complete command lines containing a `;' or `@'.
3968
3969b. The file descriptor from which the shell is reading a script is now
3970 moved to a file descriptor above the user-addressible range.
3971
3972c. Changes to `printf' so that it can handle integers beginning with 0
3973 or 0x as octal and hex, respectively.
3974
3975d. Fixes to the programmable completion code so it handles nonsense like
3976 `compgen -C xyz' gracefully.
3977
3978e. The shell no longer modifies the signal handler for SIGPROF, allowing
3979 profiling again on certain systems.
3980
3981f. The shell checks for a new window size, if the user has requested it,
3982 after a process exits due to a signal.
3983
3984g. Fixed a bug with variables with null values in a program's temporary
3985 environment and the bash getenv() replacement.
3986
3987h. `declare' and the other builtins that take variable assignments as
3988 arguments now honor `set -a' and mark modified variables for export.
3989
3990i. Some changes were made for --dump-po-strings mode when writing strings
3991 with embedded newlines.
3992
3993j. The code that caches export strings from the initial environment now
3994 duplicates the string rather than just pointing into the environment.
3995
3996k. The filename completion quoting code now uses single quotes by default
3997 if the filename being completed contains newlines, since \<newline>
3998 has a special meaning to the parser.
3999
4000l. Bash now uses typedefs bits32_t and u_bits32_t instead of int32_t and
4001 u_int32_t, respectively to avoid conflicts on certain Unix versions.
4002
4003m. Configuration changes were made for: Rhapsody, Mac OS, FreeBSD-3.x.
4004
4005n. Fixed a problem with hostname-to-ip-address translation in the
4006 /dev/(tcp|udp)/hostname/port redirection code.
4007
4008o. The texinfo manual has been reorganized slightly.
4009
4010p. Filename generation (globbing) range comparisons in bracket expressions
4011 no longer use strcoll(3) even if it is available, since it has unwanted
4012 effects in certain locales.
4013
4014q. Fixed a cosmetic problem in the source that caused the shell to not
4015 compile if DPAREN_ARITHMETIC was not defined but ARITH_FOR_COMMAND was.
4016
4017r. Fixed a bug in the here-document code tripped when the file descriptor
4018 opened to the file containing the text of the here document was the
4019 same as a redirector specified by the user.
4020
4021s. Fixed a bug where the INVERT_RETURN flag was not being set for `pipeline'
4022 in `time ! pipeline'.
4023
4024t. Fixed a bug with the `wait' builtin which manifested itself when an
4025 interrupt was received while the shell was waiting for asynchronous
4026 processes in a shell script.
4027
4028u. Fixed the DEBUG trap code so that it has the correct value of $?.
4029
4030v. Fixed a bug in the parameter pattern substitution code that could cause
4031 the shell to attempt to free unallocated memory if the pattern started
4032 with `/' and an expansion error occurs.
4033
4034w. Fixed a bug in the positional parameter substring code that could
4035 cause the shell to loop freeing freed memory.
4036
4037x. Fixed a bug in the positional parameter pattern substitution code so
4038 that it correctly handles null replacement strings with a pattern
4039 string prefixed with `%' or `#'.
4040
4041y. The shell no longer attempts to import functions from the environment if
4042 started with `-n'.
4043
4044z. Fixed a bug that caused `return' in a command substitution executed in
4045 a shell function to return from the function in a subshell and continue
4046 execution.
4047
4048aa. `hash -p /pathname/with/slashes name' is no longer allowed when the shell
4049 is restricted.
4050
4051bb. The wait* job control functions now behave better if called when there
4052 are no unwaited-for children.
4053
4054cc. Command substitution no longer unconditionally disables job control in
4055 the subshell started to run the command.
4056
4057dd. A bug was fixed that occasionally caused traps to mess up the parser
4058 state.
4059
4060ee. `bashbug' now honors user headers in the mail message it sends.
4061
4062ff. A bug was fixed that caused the `:p' history modifier to not print the
4063 history expansion if the `histverify' option was set.
4064
40652. Changes to Readline
4066
4067a. Fixed a bug in the redisplay code for lines with more than 256 line
4068 breaks.
4069
4070b. A bug was fixed which caused invisible character markers to not be
4071 stripped from the prompt string if the terminal was in no-echo mode.
4072
4073c. Readline no longer tries to get the variables it needs for redisplay
4074 from the termcap entry if the calling application has specified its
4075 own redisplay function. Readline treats the terminal as `dumb' in
4076 this case.
4077
4078d. Fixes to the SIGWINCH code so that a multiple-line prompt with escape
4079 sequences is redrawn correctly.
4080
40813. New Features in Bash
4082
4083a. `bashbug' now accepts `--help' and `--version' options.
4084
4085b. There is a new `xpg_echo' option to `shopt' that controls the behavior
4086 of echo with respect to backslash-escaped characters at runtime.
4087
4088------------------------------------------------------------------------------
4089This document details the changes between this version, bash-2.04-alpha1,
4090and the previous version, bash-2.04-devel.
4091
40921. Changes to Bash
4093
4094a. Fixed a bug that could cause core dumps when performing substring
4095 expansion.
4096
4097b. Shared object configuration changes for: Solaris, OSF/1
4098
4099c. The POSIX_GLOB_LIBRARY code that uses the POSIX.2 globbing facilities
4100 for pathname expansion now understands GLOBIGNORE.
4101
4102d. The code that implements `eval' was changed to save the value of the
4103 current prompt, so an eval in a shell function called by the programmable
4104 completion code will not change the prompt to $PS2.
4105
4106e. Restored the undocumented NON_INTERACTIVE_LOGIN_SHELLS #define to
4107 config-top.h. If this is defined, all login shells will read the
4108 startup files, not just interactive and non-interactive started with
4109 the `--login' option.
4110
4111f. Fixed a bug that caused the expansion code to occasionally dump core if
4112 IFS contained characters > 128.
4113
4114g. Fixed a problem with the grammar so that a newline is not required
4115 after the `))' in the new-style arithmetic for statement; a semicolon
4116 may be used as expected.
4117
4118h. Variable indirection may now reference the shell's special variables.
4119
4120i. The $'...' and $"..." constructs are now added to the history correctly
4121 if they contain newlines and command-oriented history is enabled.
4122
4123j. It is now an error to try to assign a value to a function-local copy
4124 of a readonly shell variable (declared with the `local' builtin).
4125
41262. Changes to Readline
4127
4128a. The history file code now uses O_BINARY mode when reading and writing
4129 the history file on cygwin32.
4130
41313. New Features in Bash
4132
4133a. A new programmable completion facility, with two new builtin commands:
4134 complete and compgen.
4135
4136b. configure has a new option, `--enable-progcomp', to compile in the
4137 programmable completion features (enabled by default).
4138
4139c. `shopt' has a new option, `progcomp', to enable and disable programmable
4140 completion at runtime.
4141
4142d. Unsetting HOSTFILE now clears the list of hostnames used for completion.
4143
41444. New Features in Readline
4145
4146a. A new variable, rl_gnu_readline_p, always 1. The intent is that an
4147 application can verify whether or not it is linked with the `real'
4148 readline library or some substitute.
4149
4150------------------------------------------------------------------------------
4151This document details the changes between this version, bash-2.04-devel,
4152and the previous version, bash-2.03-release.
4153
41541. Changes to Bash
4155
4156a. System-specific configuration and source changes for: Interix, Rhapsody
4157
4158b. Fixed a bug in execute_cmd.c that resulted in a compile-time error if
4159 JOB_CONTROL was not defined.
4160
4161c. An obscure race condition in the trap code was fixed.
4162
4163d. The string resulting from $'...' is now requoted to avoid any further
4164 expansion.
4165
4166e. The $'...' quoting syntax now allows backslash to escape a single quote,
4167 for ksh-93 compatibility.
4168
4169f. The $"..." quoting syntax now escapes backslashes and double quotes in
4170 the translated string when displaying them with the --dump-po-strings
4171 option.
4172
4173g. `echo -e' no longer converts \' to '.
4174
4175h. Fixes were made to the extended globbing code to handle embedded (...)
4176 patterns better.
4177
4178i. Some improvements were made to the code that unsets `nodelay' mode on
4179 the file descriptor from which bash is reading input.
4180
4181j. Some changes were made to the replacement termcap library for better
4182 operation on MS-DOS.
4183
4184k. Some changes were made to the tilde expansion code to handle backslash
4185 as a pathname separator on MS-DOS.
4186
4187l. The source has been reorganized a little bit -- there is now an `include'
4188 subdirectory, and lib/posixheaders has been removed.
4189
4190m. Improvements were made to the `read' builtin so that it makes many
4191 fewer read(2) system calls.
4192
4193n. The expansion of $- will include `c' and `s' when those options are
4194 supplied at shell invocation.
4195
4196o. Several improvments were made to the completion code: variable completion
4197 now works better when there are unterminated expansions, command
4198 completion understands quotes better, and completion now works in certain
4199 unclosed $(... constructs.
4200
4201p. The arithmetic expansion code was fixed to not need the value of a
4202 variable being assigned a value (fixes the "ss=09; let ss=10" bug).
4203
4204q. Some changes were made to make exported environment creation faster.
4205
4206r. The html documentation will be installed into $(htmldir) if that variable
4207 has a value when `make install' is run.
4208
4209s. Fixed a bug that would cause the bashrc file to be sourced inappropriately
4210 when bash is started by sshd.
4211
4212t. The SSH_CLIENT environment variable is no longer auto-exported.
4213
4214u. A bug that caused redirections with (...) subshells to be performed in
4215 the wrong order was fixed.
4216
28ef6c31 4217v. A bug that occasionally caused inappropriate expansion of assignment
bb70624e
JA
4218 statements in compound array assignments was fixed.
4219
4220w. The code that parses the words in a compound array assignment was
4221 simplified considerably and should work better now.
4222
4223x. Fixes to the non-job-control code in nojobs.c to make it POSIX.2-compliant
4224 when a user attempts to retrieve the status of a terminated background
4225 process.
4226
4227y. Fixes to the `printf' builtin so that it doesn't try to expand all
4228 backslash escape sequences in the format string before parsing it for
4229 % format specifiers.
4230
42312. Changes to Readline
4232
4233a. The history library tries to truncate the history file only if it is a
4234 regular file.
4235
4236b. A bug that caused _rl_dispatch to address negative array indices on
4237 systems with signed chars was fixed.
4238
4239c. rl-yank-nth-arg now leaves the history position the same as when it was
4240 called.
4241
4242d. Changes to the completion code to handle MS-DOS drive-letter:pathname
4243 filenames.
4244
4245e. Completion is now case-insensitive by default on MS-DOS.
4246
4247f. Fixes to the history file manipulation code for MS-DOS.
4248
4249g. Readline attempts to bind the arrow keys to appropriate defaults on MS-DOS.
4250
4251h. Some fixes were made to the redisplay code for better operation on MS-DOS.
4252
4253i. The quoted-insert code will now insert tty special chars like ^C.
4254
4255j. A bug was fixed that caused the display code to reference memory before
4256 the start of the prompt string.
4257
4258k. More support for __EMX__ (OS/2).
4259
4260l. A bug was fixed in readline's signal handling that could cause infinite
4261 recursion in signal handlers.
4262
4263m. A bug was fixed that caused the point to be less than zero when rl_forward
4264 was given a very large numeric argument.
4265
4266n. The vi-mode code now gets characters via the application-settable value
4267 of rl_getc_function rather than calling rl_getc directly.
4268
42693. New Features in Bash
4270
4271a. The history builtin has a `-d offset' option to delete the history entry
4272 at position `offset'.
4273
4274b. The prompt expansion code has two new escape sequences: \j, the number of
4275 active jobs; and \l, the basename of the shell's tty device name.
4276
4277c. The `bind' builtin has a new `-x' option to bind key sequences to shell
4278 commands.
4279
4280d. There is a new shell option, no_empty_command_completion, which, when
4281 enabled, disables command completion when TAB is typed on an empty line.
4282
4283e. The `help' builtin has a `-s' option to just print a builtin's usage
4284 synopsys.
4285
4286f. There are several new arithmetic operators: id++, id-- (variable
4287 post-increment/decrement), ++id, --id (variabl pre-increment/decrement),
4288 expr1 , expr2 (comma operator).
4289
4290g. There is a new ksh-93 style arithmetic for command:
4291 for ((expr1 ; expr2; expr3 )); do list; done
4292
4293h. The `read' builtin has a number of new options:
4294 -t timeout only wait timeout seconds for input
4295 -n nchars only read nchars from input instead of a full line
4296 -d delim read until delim rather than newline
4297 -s don't echo input chars as they are read
4298
4299i. The redirection code now handles several filenames specially:
4300 /dev/fd/N, /dev/stdin, /dev/stdout, and /dev/stderr, whether or
4301 not they are present in the file system.
4302
4303j. The redirection code now recognizes pathnames of the form
4304 /dev/tcp/host/port and /dev/udp/host/port, and tries to open a socket
4305 of the appropriate type to the specified port on the specified host.
4306
4307k. The ksh-93 ${!prefix*} expansion, which expands to the names of all
4308 shell variables whose names start with prefix, has been implemented.
4309
4310l. There is a new dynamic variable, FUNCNAME, which expands to the name of
4311 a currently-executing function. Assignments to FUNCNAME have no effect.
4312
4313m. The GROUPS variable is no longer readonly; assignments to it are silently
4314 discarded. This means it can be unset.
4315
43164. New Features in Readline
4317
4318a. Parentheses matching is now always compiled into readline, and enabled
4319 or disabled when the value of the `blink-matching-paren' variable is
4320 changed.
4321
4322b. MS-DOS systems now use ~/_inputrc as the last-ditch inputrc filename.
4323
4324c. MS-DOS systems now use ~/_history as the default history file.
4325
4326d. history-search-{forward,backward} now leave the point at the end of the
4327 line when the string to search for is empty, like
4328 {reverse,forward}-search-history.
4329
4330e. history-search-{forward,backward} now leave the last history line found
4331 in the readline buffer if the second or subsequent search fails.
4332
4333f. New function for use by applications: rl_on_new_line_with_prompt, used
4334 when an application displays the prompt itself before calling readline().
4335
4336g. New variable for use by applications: rl_already_prompted. An application
4337 that displays the prompt itself before calling readline() must set this to
4338 a non-zero value.
4339
4340------------------------------------------------------------------------------
b72432fd
JA
4341This document details the changes between this version, bash-2.03-release,
4342and the previous version, bash-2.03-beta2.
4343
43441. Changes to Bash
4345
4346a. A file descriptor leak in the `fc' builtin was fixed.
4347
4348b. A bug was fixed in the `read' builtin that caused occasional spurious
4349 failures when using `read -e'.
4350
4351c. The version code needed to use the value of the cpp variable
4352 CONF_MACHTYPE rather than MACHTYPE.
4353
4354d. A new test was added to exercise the command printing and copying code.
4355
4356e. A bug was fixed that caused `time' to be recognized as a reserved word
4357 if it was the first pattern in a `case' statement pattern list.
4358
4359------------------------------------------------------------------------------
4360This document details the changes between this version, bash-2.03-beta2,
4361and the previous version, bash-2.03-beta1.
4362
43631. Changes to Bash
4364
4365a. Slight additions to support/shobj-conf, mostly for the benefit of AIX 4.2.
4366
4367b. config.{guess,sub} support added for the NEC SX4.
4368
4369c. Changed some of the cross-compiling sections of the configure macros in
4370 aclocal.m4 so that configure won't abort.
4371
4372d. Slight changes to how the HTML versions of the bash and readline manuals
4373 are generated.
4374
4375e. Fixed conditional command printing to avoid interpreting printf `%'-escapes
4376 in arguments to [[.
4377
4378f. Don't include the bash malloc on all variants of the alpha processor.
4379
4380g. Changes to configure to make --enable-profiling work on Solaris 2.x.
4381
4382h. Fixed a bug that manifested itself when shell functions were called
4383 between calls to `getopts'.
4384
4385i. Fixed pattern substitution so that a bare `#'as a pattern causes the
4386 replacement string to be prefixed to the search string, and a bare
4387 `%' causes the replacement string to be appended to the search string.
4388
4389j. Fixed a bug in the command execution code that caused child processes
4390 to occasionally have the wrong value for $!.
4391
43922. Changes to Readline
4393
4394a. Added code to the history library to catch history substitutions using
4395 `&' without a previous history substitution or search having been
4396 performed.
4397
43983. New Features in Bash
4399
44004. New Features in Readline
4401
4402a. New bindable variable: `isearch-terminators'.
4403
4404b. New bindable function: `forward-backward-delete-char' (unbound by default).
4405
4406------------------------------------------------------------------------------
4407This document details the changes between this version, bash-2.03-beta1,
4408and the previous version, bash-2.03-alpha.
4409
44101. Changes to Bash
4411
4412a. A change was made to the help text for `{...}' to make it clear that a
4413 semicolon is required before the closing brace.
4414
4415b. A fix was made to the `test' builtin so that syntax errors cause test
4416 to return an exit status > 1.
4417
4418c. Globbing is no longer performed on assignment statements that appear as
4419 arguments to `assignment builtins' such as `export'.
4420
4421d. System-specific configuration changes were made for: Rhapsody,
4422 AIX 4.2/gcc, BSD/OS 4.0.
4423
4424e. New loadable builtins: ln, unlink.
4425
4426f. Some fixes were made to the globbing code to handle extended glob patterns
4427 which immediately follow a `*'.
4428
4429g. A fix was made to the command printing code to ensure that redirections
4430 following compound commands have a space separating them from the rest
4431 of the command.
4432
4433h. The pathname canonicalization code was changed to produce fewer leading
4434 `//' sequences, since those are interpreted as network file system
4435 pathnames on some systems.
4436
4437i. A fix was made so that loops containing `eval' commands in commands passed
4438 to `bash -c' would not exit prematurely.
4439
4440j. Some changes were made to the job reaping code when the shell is not
4441 interactive, so the shell will retain exit statuses longer for examination
4442 by `wait'.
4443
4444k. A fix was made so that `jobs | command' works again.
4445
4446l. The erroneous compound array assignment var=((...)) is now a syntax error.
4447
4448m. A change was made to the dynamic loading code in `enable' to support
4449 Tenon's MachTen.
4450
4451n. A fix was made to the globbing code so that extended globbing patterns
4452 will correctly match `.' in a bracket expression.
4453
44542. Changes to Readline
4455
4456a. A fix was made to the completion code in which a typo caused the wrong
4457 value to be passed to the function that computed the longest common
4458 prefix of the list of matches.
4459
4460b. The completion code now checks the value of rl_filename_completion_desired,
4461 which is set by application-supplied completion functions to indicate
4462 that filename completion is being performed, to decide whether or not to
4463 call an application-supplied `ignore completions' function.
4464
44653. New Features in Bash
4466
4467a. A change was made to the startup file code so that any shell begun with
4468 the `--login' option, even non-interactive shells, will source the login
4469 shell startup files.
4470
44714. New Features in Readline
4472
4473a. A new variable, rl_erase_empty_line, which, if set by an application using
4474 readline, will cause readline to erase, prompt and all, lines on which the
4475 only thing typed was a newline.
4476
4477------------------------------------------------------------------------------
4478This document details the changes between this version, bash-2.03-alpha,
4479and the previous version, bash-2.02.1-release.
4480
44811. Changes to Bash
4482
4483a. System-specific configuration changes were made for: Irix 6.x, Unixware 7.
4484
4485b. The texi2dvi and texi2html scripts were updated to the latest versions
4486 from the net.
4487
4488c. The configure tests that determine which native type is 32 bits were
4489 changed to not require a compiled program.
4490
4491d. Fixed a bug in shell_execve that could cause memory to be freed twice
4492 after a failed exec.
4493
4494e. The `printf' test uses `diff -a' if it's available to prevent confusion
4495 due to the non-ascii output.
4496
4497f. Shared object configuration is now performed by a shell script,
4498 support/shobj-conf, which generates values to be substituted into
4499 makefiles by configure.
4500
4501g. Some changes were made to `ulimit' to avoid the use of RLIM_INVALID as a
4502 return value.
4503
4504h. Changes were made to `ulimit' to work around HPUX 9.x's peculiar
4505 handling of RLIMIT_FILESIZE.
4506
4507i. Some new loadable builtins were added: id, printenv, sync, whoami, push,
4508 mkdir. `pushd', `popd', and `dirs' can now be built as regular or
4509 loadable builtins from the same source file.
4510
4511j. Changes were made to `printf' to handle NUL bytes in the expanded format
4512 string.
4513
4514k. The various `make clean' Makefile targets now descend into lib/sh.
4515
4516l. The `type' builtin was changed to use the internal `getopt' so that things
4517 like `type -ap' work as expected.
4518
4519m. There is a new configuration option, --with-installed-readline, to link
4520 bash with a locally-installed version of readline. Only readline version
4521 4.0 and later releases can support this. Shared and static libraries
4522 are supported. The installed include files are used.
4523
4524n. There is a new autoconf macro used to find which basic type is 64 bits.
4525
4526o. Dynamic linking and loadable builtins should now work on SCO 3.2v5*,
4527 AIX 4.2 with gcc, Unixware 7, and many other systems using gcc, where
4528 the `-shared' options works correctly.
4529
4530p. A bug was fixed in the bash filename completion code that caused memory to
4531 be freed twice if a directory name containing an unset variable was
4532 completed and the -u option was set.
4533
4534q. The prompt expansion code now quotes the `$' in the `\$' expansion so it
4535 is not processed by subsequent parameter expansion.
4536
4537r. Fixed a parsing bug that caused a single or double quote after a `$$' to
4538 trigger ANSI C expansion or locale translation.
4539
4540s. Fixed a bug in the globbing code that caused quoted filenames containing
4541 no globbing characters to sometimes be incorrectly expanded.
4542
4543t. Changes to the default prompt strings if prompt string decoding is not
4544 compiled into the shell.
4545
4546u. Added `do', `then', `else', `{', and `(' to the list of keywords that may
4547 precede the `time' reserved word.
4548
4549v. The shell may now be cross-built for BeOS as well as cygwin32.
4550
4551w. The conditional command execution code now treats `=' the same as `=='
4552 for deciding when to perform pattern matching.
4553
4554x. The `-e' option no longer causes the shell to exit if a command exits
4555 with a non-zero status while running the startup files.
4556
4557y. The `printf' builtin no longer dumps core if a modifier is supplied in
4558 the format string without a conversion character (e.g. `%h').
4559
4560z. Array assignments of the form a=(...) no longer show up in the history
4561 list.
4562
4563aa. The parser was fixed to obey the POSIX.2 rules for finding the closing
4564 `}' in a ${...} expression.
4565
4566bb. The history file is now opened with mode 0600 rather than 0666, so bash
4567 no longer relies on the user's umask being set appropriately.
4568
4569cc. Setting LANG no longer causes LC_ALL to be assigned a value; bash now
4570 relies on proper behavior from the C library.
4571
4572dd. Minor changes were made to allow quoted variable expansions using
4573 ${...} to be completed correctly if there is no closing `"'.
4574
4575ee. Changes were made to builtins/Makefile.in so that configuring the shell
4576 with `--enable-profiling' works right and builtins/mkbuiltins is
4577 generated.
4578
45792. Changes to Readline
4580
4581a. The version number is now 4.0.
4582
4583b. There is no longer any #ifdef SHELL code in the source files.
4584
4585c. Some changes were made to the key binding code to fix memory leaks and
4586 better support Win32 systems.
4587
4588d. Fixed a silly typo in the paren matching code -- it's microseconds, not
4589 milliseconds.
4590
4591e. The readline library should be compilable by C++ compilers.
4592
4593f. The readline.h public header file now includes function prototypes for
4594 all readline functions, and some changes were made to fix errors in the
4595 source files uncovered by the use of prototypes.
4596
4597g. The maximum numeric argument is now clamped at 1000000.
4598
4599h. Fixes to rl_yank_last_arg to make it behave better.
4600
4601i. Fixed a bug in the display code that caused core dumps if the prompt
4602 string length exceeded 1024 characters.
4603
4604j. The menu completion code was fixed to properly insert a single completion
4605 if there is only one match.
4606
4607k. A bug was fixed that caused the display code to improperly display tabs
4608 after newlines.
4609
46103. New Features in Bash
4611
4612a. New `shopt' option, `restricted_shell', indicating whether or not the
4613 shell was started in restricted mode, for use in startup files.
4614
4615b. Filename generation is now performed on the words between ( and ) in
4616 array assignments (which it probably should have done all along).
4617
4618c. OLDPWD is now auto-exported, as POSIX.2 seems to require.
4619
4620d. ENV and BASH_ENV are read-only variables in a restricted shell.
4621
46224. New Features in Readline
4623
4624a. Many changes to the signal handling:
4625 o Readline now catches SIGQUIT and cleans up the tty before returning;
4626 o A new variable, rl_catch_signals, is available to application writers
4627 to indicate to readline whether or not it should install its own
4628 signal handlers for SIGINT, SIGTERM, SIGQUIT, SIGALRM, SIGTSTP,
4629 SIGTTIN, and SIGTTOU;
4630 o A new variable, rl_catch_sigwinch, is available to application
4631 writers to indicate to readline whether or not it should install its
4632 own signal handler for SIGWINCH, which will chain to the calling
4633 applications's SIGWINCH handler, if one is installed;
4634 o There is a new function, rl_free_line_state, for application signal
4635 handlers to call to free up the state associated with the current
4636 line after receiving a signal;
4637 o There is a new function, rl_cleanup_after_signal, to clean up the
4638 display and terminal state after receiving a signal;
4639 o There is a new function, rl_reset_after_signal, to reinitialize the
4640 terminal and display state after an application signal handler
4641 returns and readline continues
4642
4643b. There is a new function, rl_resize_terminal, to reset readline's idea of
4644 the screen size after a SIGWINCH.
4645
4646c. New public functions: rl_save_prompt and rl_restore_prompt. These were
4647 previously private functions with a `_' prefix.
4648
4649d. New function hook: rl_pre_input_hook, called just before readline starts
4650 reading input, after initialization.
4651
4652e. New function hook: rl_display_matches_hook, called when readline would
4653 display the list of completion matches. The new function
4654 rl_display_match_list is what readline uses internally, and is available
4655 for use by application functions called via this hook.
4656
4657f. New bindable function, delete-char-or-list, like tcsh.
4658
4659------------------------------------------------------------------------------
bc4cd23c
JA
4660This document details the changes between this version, bash-2.02.1-release,
4661and the previous version, bash-2.02-release.
4662
46631. Changes to Bash
4664
4665a. A bug that caused the bash readline support to not compile unless aliases
4666 and csh-style history were configured into the shell was fixed.
4667
4668b. Fixed a bug that could cause a core dump when here documents contained
4669 more than 1000 characters.
4670
4671c. Fixed a bug that caused a CDPATH entry of "" to not be treated the same
4672 as the current directory when in POSIX mode.
4673
4674d. Fixed an alignment problem with the memory returned by the bash malloc,
4675 so returned memory is now 64-bit aligned.
4676
4677e. Fixed a bug that caused command substitutions executed within pipelines
4678 to put the terminal in the wrong process group.
4679
4680f. Fixes to support/config.sub for: alphas, SCO Open Server and Open Desktop,
4681 Unixware 2, and Unixware 7.
4682
4683g. Fixes to the pattern matching code to make it work correctly for eight-bit
4684 characters.
4685
4686h. Fixed a problem that occasionally caused the shell to display the wrong
4687 value for the new working directory when changing to a directory found
4688 in $CDPATH when in physical mode.
4689
4690i. Fixed a bug that caused core dumps when using conditional commands in
4691 shell functions.
4692
4693j. Fixed a bug that caused the printf builtin to loop forever if the format
4694 string did not consume any of the arguments.
4695
4696k. Fixed a bug in the parameter expansion code that caused "$@" to be
4697 incorrectly split if $IFS did not contain a space character.
4698
4699l. Fixed a bug that could cause a core dump when completing hostnames if
4700 the number of matching hostnames was an exact multiple of 16.
4701
4702m. Fixed a bug that caused the shell to fork too early when a command
4703 such as `%2 &' was given.
4704
47052. Changes to Readline
4706
4707a. Fixed a problem with redisplay that showed up when the prompt string was
4708 longer than the screen width and the prompt contained invisible characters.
4709
4710------------------------------------------------------------------------------
4711This document details the changes between this version, bash-2.02-release,
4712and the previous version, bash-2.02-beta2.
cce855bc
JA
4713
47141. Changes to Bash
4715
4716a. A bug was fixed that caused the terminal process group to be set
4717 incorrectly when performing command substitution of builtins in a
4718 pipeline.
4719
4720------------------------------------------------------------------------------
4721This document details the changes between this version, bash-2.02-beta2,
4722and the previous version, bash-2.02-beta1.
4723
47241. Changes to Bash
4725
4726a. Attempting to `wait' for stopped jobs now generates a warning message.
4727
4728b. Pipelines which exit due to SIGPIPE in non-interactive shells are now
4729 not reported if the shell is compiled -DDONT_REPORT_SIGPIPE.
4730
4731c. Some changes were made to builtins/psize.sh and support/bashbug.sh to
4732 attempt to avoid some /tmp file races and surreptitious file
4733 substitutions.
4734
4735d. Fixed a bug that caused the shell not to compile if configured with
4736 dparen arithmetic but without aliases.
4737
4738e. Fixed a bug that caused the input stream to be switched when assigning
4739 empty arrays with `bash -c'.
4740
4741f. A bug was fixed in the readline expansion glue code that caused bash to
4742 dump core when expanding lines with an unclosed single quote.
4743
4744g. A fix was made to the `cd' builtin so that using a non-empty directory
4745 from $CDPATH results in an absolute pathname of the new current working
4746 directory to be displayed after the current directory is changed.
4747
4748h. Fixed a bug in the variable assignment code that caused the shell to
4749 dump core when referencing an unset variable with `set -u' enabled in
4750 an assignment statement preceding a command.
4751
4752i. Fixed a bug in the exit trap code that caused reserved words to not be
4753 recognized under certain circumstances.
4754
4755j. Fixed a bug in the parameter pattern substitution code so that quote
4756 removal is performed.
4757
4758k. The shell should now configure correctly on Apple Rhapsody systems.
4759
4760l. The `kill' builtin now prints a usage message if it is not passed any
4761 arguments.
4762
4763------------------------------------------------------------------------------
4764This document details the changes between this version, bash-2.02-beta1,
4765and the previous version, bash-2.02-alpha1.
4766
47671. Changes to Bash
4768
4769a. A few compilation bugs were fixed in the new extended globbing code.
4770
4771b. Executing arithmetic commands now sets the command name to `((' so
4772 error messages look right.
4773
4774c. Fixed some build problems with various configuration options.
4775
4776d. The `printf' builtin now aborts immediately if an illegal format
4777 character is encountered.
4778
4779e. The code that creates here-documents now behaves better if the file it's
4780 trying to create already exists for some reason.
4781
4782f. Fixed a problem with the extended globbing code that made patterns like
4783 `x+*' expand incorrectly.
4784
4785g. The prompt string expansion code no longer quotes tildes with backslashes.
4786
4787h. The bash getcwd() implementation in lib/sh/getcwd.c now behaves better in
4788 the presence of lstat(2) failures.
4789
4790i. Fixed a bug with strsub() that caused core dumps when executing `fc -s'.
4791
4792j. The mail checking code now ensures that it has a valid default mailpath.
4793
4794k. A bug was fixed that caused local variables to be unset inappropriately
4795 when sourcing a script from within another sourced script.
4796
4797l. A bug was fixed in the history saving code so that functions are saved
4798 in the history list correctly if `cmdhist' is enabled, but `lithist'
4799 is not.
4800
4801m. A bug was fixed that caused printf overflows when displaying error
4802 messages.
4803
4804n. It should be easier to build the loadble builtins in examples/loadables,
4805 though some manual editing of the generated Makefile is still required.
4806
4807o. The user's primary group is now always ${GROUPS[0]}.
4808
4809p. Some updates were made to support/config.guess from the GNU master copy.
4810
4811q. Some changes were made to the autoconf support for Solaris 2.6 large
4812 files.
4813
4814r. The `command' builtins now does the right thing when confstr(3) cannot
4815 find a value for _CS_PATH.
4816
4817s. Extended globbing expressions like `*.!(c)' are not history expanded if
4818 `extglob' is enabled.
4819
4820t. Using the `-P' option to `cd' will force the value that is assigned to
4821 PWD to not contain any symbolic links.
4822
48232. Changes to Readline
4824
4825a. The code that prints completion listings now behaves better if one or
4826 more of the filenames contains non-printable characters.
4827
4828b. The time delay when showing matching parentheses is now 0.5 seconds.
4829
4830------------------------------------------------------------------------------
4831This document details the changes between this version, bash-2.02-alpha1,
4832and the previous version, bash-2.01.1-release.
4833
48341. Changes to Bash
4835
4836a. OS-specific configuration changes for: BSD/OS 3.x, Minix 2.x,
4837 Solaris 2.6, SINIX SVR4.
4838
4839b. Changes were made to the generated `info' files so that `install-info'
4840 works correctly.
4841
4842c. PWD is now auto-exported.
4843
4844d. A fix was made to the pipeline code to make sure that the shell forks
4845 to execute simple commands consisting solely of assignment statements.
4846
4847e. Changes to the test suite for systems with 14-character filenames.
4848
4849f. The default sizes of some internal hash tables have been made smaller
4850 to reduce the shell's memory footprint.
4851
4852g. The `((...))' arithmetic command is now executed directly instead of
4853 being translated into `let "..."'.
4854
4855h. Fixes were made to the expansion code so that "$*", "$@", "${array[@]}",
4856 and "${array[@]}" expand correctly when IFS does not contain a space
4857 character, is unset, or is set to NULL.
4858
4859i. The indirect expansion code (${!var}) was changed so that the only
4860 valid values of `var' are variable names, positional parameters, `#',
4861 `@', and `*'.
4862
4863j. An arithmetic expression error in a $((...)) expansion now causes a
4864 non-interactive shell running in posix mode to exit.
4865
4866k. Compound array assignment now splits the words within the parentheses
4867 on shell metacharacters like the parser would before expansing them
4868 and performing the assignment. This is for compatibility with ksh-93.
4869
4870l. The internal shell backslash-quoting code (used in the output of `set'
4871 and completion) now quotes tildes if they appear at the start of the
4872 string or after a `=' or `:'.
4873
4874m. A couple of bugs with `shopt -o' were fixed.
4875
4876n. `bash +o' now displays the same output as `set +o' before starting an
4877 interactive shell.
4878
4879o. A bug that caused command substitution and the `eval' builtin to
4880 occasionally free memory twice when an error was encountered was fixed.
4881
4882p. The filename globbing code no longer requires read permission for a
4883 directory when the filename to be matched does not contain any globbing
4884 characters, as POSIX.2 specifies.
4885
4886q. A bug was fixed so that the job containing the last asynchronous
4887 process is not removed from the job table until a `wait' is executed
4888 for that process or another asynchronous process is started. This
4889 satisfies a POSIX.2 requirement.
4890
4891r. A `select' bug was fixed so that a non-numeric user response is treated
4892 the same as a numeric response that is out of range.
4893
4894s. The shell no longer parses the value of SHELLOPTS from the environment
4895 if it is restricted, running setuid, or running in `privileged mode'.
4896
4897t. Fixes were made to enable large file support on systems such as
4898 Solaris 2.6, where the size of a file may be larger than can be held
4899 in an `int'.
4900
4901u. The filename hashing code was fixed to not add `./' to the beginning of
4902 filenames which already begin with `./'.
4903
4904v. The configure script was changed so that the GNU termcap library is not
4905 compiled in if `prefer-curses' has been specified.
4906
4907w. HISTCONTROL and HISTIGNORE are no longer applied to the second and
4908 subsequent lines of a multi-line command.
4909
4910x. A fix was made to `disown' so that it does a better job of catching
4911 out-of-range jobs.
4912
4913y. Non-interactive shells no longer report the status of processes terminated
4914 due to SIGINT, even if the standard output is a terminal.
4915
4916z. A bug that caused the output of `jobs' to have extra carriage returns
4917 was fixed.
4918
4919aa. A bug that caused PIPESTATUS to not be set when builtins or shell
4920 functions were executed in the foreground was fixed.
4921
4922bb. Bash now attempts to detect when it is being run by sshd, and treats
4923 that case identically to being run by rshd.
4924
4925cc. A bug that caused `set -a' to export SHELLOPTS when one of the shell
4926 options was changed was fixed.
4927
4928dd. The `kill' builtin now disallows empty or missing process id arguments
4929 instead of treating them as identical to `0', which means the current
4930 process.
4931
4932ee. `var=value declare -x var' now behaves identically to
4933 `var=value export var'. Similarly for `var=value declare -r var' and
4934 `var=value readonly var'.
4935
4936ff. A few memory leaks were fixed.
4937
4938gg. `alias' and `unalias' now print error messages when passed an argument
4939 that is not an alias for printing or deletion, even when the shell is
4940 not interactive, as POSIX.2 specifies.
4941
4942hh. `alias' and `alias -p' now return a status of 0 when no aliases are
4943 defined, as POSIX.2 specifes.
4944
4945ii. `cd -' now prints the pathname of the new working directory if the shell
4946 is interactive.
4947
4948jj. A fix was made so that the code that binds $PWD now copes with getcwd()
4949 returning NULL.
4950
4951kk. `unset' now checks whether or not a function name it's trying to unset
4952 is a valid shell identifier only when the shell is running in posix mode.
4953
4954ll. A change was made to the code that generates filenames for here documents
4955 to make them less prone to name collisions.
4956
4957mm. The parser was changed so that `time' is recognized as a reserved word
4958 only at the beginning of a pipeline.
4959
4960nn. The pathname canonicalization code was changed so that `//' is converted
4961 into `/', but all other pathnames beginning with `//' are left alone, as
4962 POSIX.2 specifies.
4963
4964oo. The `logout' builtin will no longer exit a non-interactive non-login
4965 shell.
4966
49672. Changes to Readline
4968
4969a. Fixed a problem in the readline test program rltest.c that caused a core
4970 dump.
4971
4972b. The code that handles parser directives in inputrc files now displays
4973 more error messages.
4974
4975c. The history expansion code was fixed so that the appearance of the
4976 history comment character at the beginning of a word inhibits history
4977 expansion for that word and the rest of the input line.
4978
49793. New Features in Bash
4980
4981a. A new version of malloc, based on the older GNU malloc, that has many
4982 changes, is more page-based, is more conservative with memory usage,
4983 and does not `orphan' large blocks when they are freed.
4984
4985b. A new version of gmalloc, based on the old GLIBC malloc, with many
4986 changes and range checking included by default.
4987
4988c. A new implementation of fnmatch(3) that includes full POSIX.2 Basic
4989 Regular Expression matching, including character classes, collating
4990 symbols, equivalence classes, and support for case-insensitive pattern
4991 matching.
4992
4993d. ksh-88 egrep-style extended pattern matching ([@+*?!](patlist)) has been
4994 implemented, controlled by a new `shopt' option, `extglob'.
4995
4996e. There is a new ksh-like `[[' compound command, which implements
4997 extended `test' functionality.
4998
4999f. There is a new `printf' builtin, implemented according to the POSIX.2
5000 specification.
5001
5002g. There is a new feature for command substitution: $(< filename) now expands
5003 to the contents of `filename', with any trailing newlines removed
5004 (equivalent to $(cat filename)).
5005
5006h. There are new tilde prefixes which expand to directories from the
5007 directory stack.
5008
5009i. There is a new `**' arithmetic operator to do exponentiation.
5010
5011j. There are new configuration options to control how bash is linked:
5012 `--enable-profiling', to allow bash to be profiled with gprof, and
5013 `--enable-static-link', to allow bash to be linked statically.
5014
5015k. There is a new configuration option, `--enable-cond-command', which
5016 controls whether or not the `[[' command is included. It is on by
5017 default.
5018
5019l. There is a new configuration option, `--enable-extended-glob', which
5020 controls whether or not the ksh extended globbing feature is included.
5021 It is enabled by default.
5022
5023m. There is a new configuration #define in config.h.top that, when enabled,
5024 will cause all login shells to source /etc/profile and one of the user-
5025 specific login shell startup files, whether or not the shell is
5026 interactive.
5027
5028n. There is a new invocation option, `--dump-po-strings', to dump
5029 a shell script's translatable strings ($"...") in GNU `po' format.
5030
5031o. There is a new `shopt' option, `nocaseglob', to enable case-insensitive
5032 pattern matching when globbing filenames and using the `case' construct.
5033
5034p. There is a new `shopt' option, `huponexit', which, when enabled, causes
5035 the shell to send SIGHUP to all jobs when an interactive login shell
5036 exits.
5037
5038q. `bind' has a new `-u' option, which takes a readline function name as an
5039 argument and unbinds all key sequences bound to that function in a
5040 specified keymap.
5041
5042r. `disown' now has `-a' and `-r' options, to limit operation to all jobs
5043 and running jobs, respectively.
5044
5045s. The `shopt' `-p' option now causes output to be displayed in a reusable
5046 format.
5047
5048t. `test' has a new `-N' option, which returns true if the filename argument
5049 has been modified since it was last accessed.
5050
5051u. `umask' now has a `-p' option to print output in a reusable format.
5052
5053v. A new escape sequence, `\xNNN', has been added to the `echo -e' and $'...'
5054 translation code. It expands to the character whose ascii code is NNN
5055 in hexadecimal.
5056
5057w. The prompt string expansion code has a new `\r' escape sequence.
5058
5059x. The shell may now be cross-compiled for the CYGWIN32 environment on
5060 a Unix machine.
5061
50624. New Features in Readline
5063
5064a. There is now an option for `iterative' yank-last-arg handline, so a user
5065 can keep entering `M-.', yanking the last argument of successive history
5066 lines.
5067
5068b. New variable, `print-completions-horizontally', which causes completion
5069 matches to be displayed across the screen (like `ls -x') rather than up
5070 and down the screen (like `ls').
5071
5072c. New variable, `completion-ignore-case', which causes filename completion
5073 and matching to be performed case-insensitively.
5074
5075d. There is a new bindable command, `magic-space', which causes history
5076 expansion to be performed on the current readline buffer and a space to
5077 be inserted into the result.
5078
5079e. There is a new bindable command, `menu-complete', which enables tcsh-like
5080 menu completion (successive executions of menu-complete insert a single
5081 completion match, cycling through the list of possible completions).
5082
5083f. There is a new bindable command, `paste-from-clipboard', for use on Win32
5084 systems, to insert the text from the Win32 clipboard into the editing
5085 buffer.
5086
5087g. The key sequence translation code now understands printf-style backslash
5088 escape sequences, including \NNN octal escapes. These escape sequences
5089 may be used in key sequence definitions or macro values.
5090
5091h. An `$include' inputrc file parser directive has been added.
5092
5093------------------------------------------------------------------------------
e8ce775d
JA
5094This document details the changes between this version, bash-2.01.1-release,
5095and the previous version, bash-2.01-release.
5096
50971. Changes to Bash
5098
5099a. The select command was fixed to check the validity of the user's
5100 input more strenuously.
5101
5102b. A bug was fixed that prevented `time' from timing commands correctly
5103 when supplied as an argument to `bash -c'.
5104
5105c. A fix was made to the mail checking code to keep from adding the same
5106 mail file to the list of files to check multiple times when parsing
5107 $MAILPATH.
5108
5109d. Fixed an off-by-one error in the tilde expansion library.
5110
5111e. When using the compound array assignment syntax, the old value of
5112 the array is cleared before assigning the new value.
5113
5114f. Fixed a bug that could cause a core dump when a trap handler was reset
5115 to the default in the trap command associated with that signal.
5116
5117g. Fixed a bug in the locale code that occurred when assigning a value
5118 to LC_ALL.
5119
5120h. A change was made to the parser so that words of the form xxx=(...)
5121 are not considered compound assignment statements unless there are
5122 characters before the `='.
5123
5124i. A fix was made to the command tracing code to correctly quote each
5125 word of output.
5126
5127j. Some changes were made to the bash-specific autoconf tests to make them
5128 more portable.
5129
5130k. Completion of words with globbing characters now correctly quotes the
5131 result.
5132
5133l. The directory /var/spool/mail is now preferred to /usr/spool/mail when
5134 configure is deciding on the default mail directory.
5135
5136m. The brace completion code was fixed to not quote the `{' and `}'.
5137
5138n. Some fixes were made to make $RANDOM more random in subshells.
5139
5140o. System-specific changes were made to configure for: SVR4.2
5141
5142p. Changes were made so that completion of words containing globbing chars
5143 substitutes the result only if a single filename was matched.
5144
5145q. The window size is now recomputed after a job is stopped with SIGTSTP if
5146 the user has set `checkwinsize' with `shopt'.
5147
5148r. When doing substring expansion, out-of-range substring specifiers now
5149 cause nothing to be substituted rather than an expansion error.
5150
5151s. A fix was made so that you can no longer trap `SIGEXIT' or `SIGDEBUG' --
5152 only `EXIT' and `DEBUG' are accepted.
5153
5154t. The display of trapped signals now uses the signal number if signals
5155 for which bash does not know the name are trapped.
5156
5157u. A fix was made so that `bash -r' does not turn on restricted mode until
5158 after the startup files are executed.
5159
5160v. A bug was fixed that occasionally caused a core dump when a variable
5161 found in the temporary environment of export/declare/readonly had a
5162 null value.
5163
5164w. A bug that occasionally caused unallocated memory to be passed to free()
5165 when doing arithmetic substitution was fixed.
5166
5167x. A bug that caused a buffer overrun when expanding a prompt string
5168 containing `\w' and ${#PWD} exceeded PATH_MAX was fixed.
5169
5170y. A problem with the completion code that occasionally caused it to
5171 refer to a character before the beginning of the readline line buffer
5172 was fixed.
5173
5174z. A bug was fixed so that the `read' builtin restarts reads when
5175 interrupted by signals other than SIGINT.
5176
5177aa. Fixed a bug that caused a command to be freed twice when there was
5178 an evaluation error in the `eval' command.
5179
51802. Changes to Readline
5181
5182a. Added a missing `extern' to a declaration in readline.h that kept
5183 readline from compiling cleanly on some systems.
5184
5185b. The history file is now opened with mode 0600 when it is written for
5186 better security.
5187
5188c. Changes were made to the SIGWINCH handling code so that prompt redisplay
5189 is done better.
5190
5191d. ^G now interrupts incremental searches correctly.
5192
5193e. A bug that caused a core dump when the set of characters to be quoted
5194 when completing words was empty was fixed.
5195
5196------------------------------------------------------------------------------
d166f048
JA
5197This document details the changes between this version, bash-2.01-release,
5198and the previous version, bash-2.01-beta2.
5199
52001. Changes to Bash
5201
5202a. The `distclean' target should remove the `printenv' executable if it
5203 has been created.
5204
5205b. The test suite was changed slightly to ensure that the error messages
5206 are printed in English.
5207
5208c. A bug that caused the shell to dump core when a filename containing a
5209 `/' was passed to `hash' was fixed.
5210
5211d. Pathname canonicalization now leaves a leading `//' intact, as POSIX.1
5212 requires.
5213
5214e. A memory leak when completing commands was fixed.
5215
5216f. A memory leak that occurred when checking the hash table for commands
5217 with relative paths was fixed.
5218
5219------------------------------------------------------------------------------
5220This document details the changes between this version, bash-2.01-beta2,
5221and the previous version, bash-2.01-beta1.
5222
52231. Changes to Bash
5224
5225a. The `ulimit' builtin translates RLIM_INFINITY to the hard limit only if
5226 the current (soft) limit is less than or equal to the hard limit.
5227
5228b. Fixed a bug that caused the bash emulation of strcasecmp to produce
5229 incorrect results.
5230
5231c. A bug that caused memory to be freed twice when a trap handler resets
5232 the trap more than once was fixed.
5233
5234d. A bug that caused machines where sizeof (pointer) > sizeof (int) to
5235 fail (and possibly dump core) when trying to unwind-protect a null
5236 pointer was fixed.
5237
5238e. The startup files should not be run with job control enabled. This fix
5239 allows SIGINT to once again interrupt startup file execution.
5240
5241f. Bash should not change the SIGPROF handler if it is set to something
5242 other than SIG_DFL.
5243
5244g. The completion code that provides bash-specific completions for readline
5245 now quotes characters that the readline code would treat as word break
5246 characters if they appear in a file name.
5247
5248h. The completion code now correctly quotes filenames containing a `!',
5249 even if the user attempted to use double quotes when attempting
5250 completion.
5251
5252i. A bug that caused the shell to dump core when `disown' was called without
5253 arguments and there was no current job was fixed.
5254
5255j. A construct like $((foo);bar) is now processed as a command substitution
5256 rather than as a bad arithmetic substitution.
5257
5258k. A couple of bugs that caused `fc' to not obey the `cmdhist' and `lithist'
5259 shell options when editing and re-executing a series of commands were
5260 fixed.
5261
5262l. A fix was made to the grammar -- the list of commands between `do' and
5263 `done' in the body of a `for' command should be treated the same as a
5264 while loop.
5265
52662. Changes to Readline
5267
5268a. A couple of bugs that caused the history search functions to attempt to
5269 free a NULL pointer were fixed.
5270
5271b. If the C library provides setlocale(3), readline does not need to look
5272 at various environment variables to decide whether or not to go into
5273 eight-bit mode automatically -- just check whether the current locale
5274 is not `C' or `POSIX'.
5275
5276c. If the filename completion function finds that a directory was not closed
5277 by a previous (interrupted) completion, it closes the directory with
5278 closedir().
5279
52803. New Features in Bash
5281
5282a. New bindable readline commands: history-and-alias-expand-line and
5283 alias-expand-line. The code was always in there, there was just no
5284 way to execute it.
5285
5286------------------------------------------------------------------------------
5287This document details the changes between this version, bash-2.01-beta1,
5288and the previous version, bash-2.01-alpha1.
5289
52901. Changes to Bash
5291
5292a. Fixed a problem that could cause file descriptors used for process
5293 substitution to conflict with those used explicitly in redirections.
5294
5295b. Made it easier to regenerate configure if the user changes configure.in.
5296
5297c. ${GROUPS[0]} should always be the primary group, even on systems without
5298 multiple groups.
5299
5300d. Spelling correction is no longer enabled by default.
5301
5302e. Fixes to quoting problems in `bashbug'.
5303
5304f. OS-specific configuration changes were made for: Irix 6.
5305
5306g. OS-specific code changes were made for: QNX.
5307
5308h. A more meaningful message is now printed when the file in /tmp for a
5309 here document cannot be created.
5310
5311i. Many changes to the shell's variable initialization code to speed
5312 non-interactive startup.
5313
5314j. Changes to the non-job-control code so that it does not try to open
5315 /dev/tty.
5316
5317k. The output of `set' and `export' is once again sorted, as POSIX wants.
5318
5319l. Fixed a problem caused by a recursive call reparsing the value of
5320 $SHELLOPTS.
5321
5322m. The tilde code no longer calls getenv() when it's compiled as part of
5323 the shell, which should eliminate problems on systems that cannot
5324 redefine getenv(), like the NeXT OS.
5325
5326n. Fixed a problem that caused `bash -o' or `bash +o' to not list all
5327 the shell options.
5328
5329o. Fixed `ulimit' to convert RLIM_INFINITY to the appropriate hard limit
5330 only if the hard limit is greater than the current (soft) limit.
5331
5332p. Fixed a problem that arose when building bash in a different directory
5333 than the source and y.tab.[ch] were remade with something other than
5334 bison. This came up most often on NetBSD.
5335
5336q. Fixed a problem with completion -- it thought that `pwd`/[TAB] indicated
5337 an unfinished command completion (`/), which generated errors.
5338
5339r. The bash special tilde expansions (~-, ~+) are now attempted before
5340 calling the standard tilde expansion code, which should eliminate the
5341 problems people have been seeing with this on Solaris 2.5.1.
5342
5343s. Added support for <stdarg.h> to places where it was missing.
5344
5345t. Changed the code that reads the output of a command substitution to not
5346 go through stdio. This reduces the memory requirements and is faster.
5347
5348u. A number of changes to speed up export environment creation were made.
5349
5350v. A number of memory leaks were fixed as the result of running the test
5351 scripts through Purify.
5352
5353w. Fixed a bug that caused subshells forked to interpret executable
5354 scripts without a leading `#!' to not reinitialize the values of
5355 the shell options.
5356
53572. Changes to Readline
5358
5359a. History library has less `#ifdef SHELL' code -- abstracted stuff out
5360 into application-specific function hooks.
5361
5362b. Readline no longer calls getenv() if it's compiled as part of the shell,
5363 which should eliminate problems on systems that cannot redefine getenv(),
5364 like the NeXT OS.
5365
5366c. Fixed translation of ESC when `untranslating' macro values.
5367
5368d. The region kill operation now fixes the mark if it ends up beyond the
5369 boundaries of the line after the region is deleted.
5370
53713. New Features in Bash
5372
5373a. New argument for `configure': `--with-curses'. This can be used to
5374 override the selection of the termcap library on systems where it is
5375 deficient.
5376
5377------------------------------------------------------------------------------
5378This document details the changes between this version, bash-2.01-alpha1,
5379and the previous version, bash-2.0-release.
5380
53811. Changes to Bash
5382
5383a. System-specific configuration changes for: FreeBSD, SunOS4, Irix,
5384 MachTen, QNX 4.2, Harris Night Hawk, SunOS5.
5385
5386b. System-specific code changes were made for: Linux, 4.4 BSD, QNX 4.2,
5387 HP-UX, AIX 4.2.
5388
5389c. A bug that caused the exec builtin to fail because the full pathname of
5390 the command could not be found was fixed.
5391
5392d. The code that performs output redirections is now more resistant to
5393 race conditions and possible security exploits.
5394
5395e. A bug that caused the shell to dump core when performing pattern
5396 substitutions on variable values was fixed.
5397
5398f. More hosts are now recognized by the auto-configuration mechanism
5399 (OpenBSD, QNX, others).
5400
5401g. Assignments to read-only variables that attempt to convert them to
5402 arrays are now errors.
5403
5404h. A bug that caused shell scripts using array assignments in POSIX mode
5405 to exit after the assignment was performed was fixed.
5406
5407i. The substring expansion code is now more careful about running off the
5408 ends of the expanded variable value.
5409
5410j. A bug that caused completion to fail if a backquoted command substitution
5411 appeared anywhere on the line was fixed.
5412
5413k. The `source' builtin no longer turns off history if it has been enabled
5414 in a non-interactive shell.
5415
5416l. A bug that caused the shell to crash when `disown' was given a pid
5417 instead of a job number was fixed.
5418
5419m. The `cd' spelling correction code will not try to change to `.' if no
5420 directory entries match a single-character argument.
5421
5422n. A bad variable name supplied to `declare', `export', or `readonly' no
5423 longer causes a non-interactive shell in POSIX mode to exit.
5424
5425o. Some fixes were made to the test suite to handle peculiarities of
5426 various Unix versions.
5427
5428p. The bash completion code now quotes characters that readline would
5429 treat as word breaks for completion but are not shell metacharacters.
5430
5431q. Bad options supplied at invocation now cause a usage message to be
5432 displayed.
5433
5434r. Fixes were made to the code that handles DEBUG traps so that the trap
5435 string is not freed inappropriately.
5436
5437s. Some changes were made to the bash debugger in examples/bashdb -- it
5438 should be closer to working now.
5439
5440t. A problem that caused the default filename used for mail checking to be
5441 wrong was fixed.
5442
5443u. A fix was made to the `echo' builtin so that NUL characters printed with
5444 `echo -e' do not cause the output to be truncated.
5445
5446v. A fix was made to the job control code so that the shell behaves better
5447 when monitor mode is enabled in a non-interactive shell.
5448
5449w. Bash no longer catches all of the terminating signals in a non-
5450 interactive shell until a trap is set on EXIT, which should result in
5451 quicker startup.
5452
5453x. A fix was made to the command timing code so that `time' can be used in
5454 a loop.
5455
5456y. A fix was made to the parser so that `((cmd); cmd2)' is now parsed as
b72432fd 5457 a nested subshell rather than strictly as an (erroneous) arithmetic
d166f048
JA
5458 command.
5459
5460z. A fix was made to the globbing code so that it correctly matches quoted
5461 filenames beginning with a `.'.
5462
5463aa. A bug in `fc' that caused some multi-line commands to not be stored as
5464 one command in the history when they were re-executed after editing
5465 (with `fc -e') was fixed.
5466
5467bb. The `ulimit' builtin now attempts to catch some classes of integer
5468 overflows.
5469
5470cc. The command-oriented-history code no longer attempts to add `;'
5471 inappropriately when a newline appears while reading a $(...) command
5472 substitution.
5473
5474dd. A bug that caused the shell to dump core when `help --' was executed
5475 was fixed.
5476
5477ee. A bug that caused the shell to crash when an unset variable appeared
5478 in the body of a here document after `set -u' had been executed was
5479 fixed.
5480
5481ff. Implicit input redirections from /dev/null for asynchronous commands
5482 are now handled better.
5483
5484gg. A bug that caused the shell to fail to compile when configured with
5485 `--disable-readline' was fixed.
5486
5487hh. The globbing code should now be interruptible.
5488
5489ii. Bash now notices when the `kill' builtin is used to send SIGCONT to a
5490 stopped job and adjusts the data structures accordingly, as if `bg' had
5491 been executed instead.
5492
5493jj. A bug that caused the shell to crash when mixing calls to `getopts'
5494 and `shift' on the same set of positional parameters was fixed.
5495
5496kk. The command printing code now preserves the `-p' flag to `time'.
5497
5498ll. The command printing code now handles here documents better when there
5499 are other redirections associated with the command.
5500
5501mm. The special glibc environment variable (NNN_GNU_nonoption_argv_flags_)
5502 is no longer placed into the environment of executed commands -- users
5503 of glibc had too many problems with it.
5504
5505nn. Reorganized the code that generates signames.h. The signal_names list
5506 is now more complete but may be slightly different (SIGABRT is favored
5507 over SIGIOT, for example). The preferred signal names are those
5508 listed in the POSIX.2 standard.
5509
5510oo. `bashbug' now uses a filename shorter than 14 characters for its
5511 temporary file, and asks for confirmation before sending the bug
5512 report.
5513
5514pp. A bug that caused TAB completion in vi editing mode to not be turned
5515 off when `set -o posix' was executed or back on when `set +o posix'
5516 was executed was fixed.
5517
5518qq. A bug in the brace expansion code that caused brace expansions appearing
5519 in new-style $(...) command substitutions to be inappropriately expanded
5520 was fixed.
5521
5522rr. A bug in the readline hook shell-expand-line that could cause memory to
5523 be inappropriately freed was fixed.
5524
5525ss. A bug that caused some arithmetic expressions containing `&&' and `||'
5526 to be parsed with the wrong precedence has been fixed.
5527
5528tt. References to unbound variables after `set -u' has been executed now
5529 cause the shell to exit immediately, as they should.
5530
5531uu. A bug that caused the shell to exit inappropriately when `set -e' had
5532 been executed and a command's return status was being inverted with the
5533 `!' reserved word was fixed.
5534
5535vv. A bug that could occasionally cause the shell to crash with a
5536 divide-by-zero error when timing a command was fixed.
5537
5538ww. A bug that caused parameter pattern substitution to leave stray
5539 backslashes in the replacement string when the expression is in
5540 double quotes was fixed.
5541
5542xx. The `break' and `continue' builtins now break out of all loops when an
5543 invalid count argument is supplied.
5544
5545yy. Fixed a bug that caused PATH to be set to the empty string if
5546 `command -p' is executed with PATH unset.
5547
5548zz. Fixed `kill -l signum' to print the signal name without the `SIG' prefix,
5549 as POSIX specifies.
5550
5551aaa. Fixed a bug that caused the shell to crash while setting $SHELLOPTS
5552 if there were no shell options set.
5553
5554bbb. Fixed `export -p' and `readonly -p' so that when the shell is in POSIX
5555 mode, their output is as POSIX.2 specifies.
5556
5557ccc. Fixed a bug in `readonly' so that `readonly -a avar=(...)' actually
5558 creates an array variable.
5559
5560ddd. Fixed a bug that prevented `time' from correctly timing background
5561 pipelines.
5562
55632. Changes to Readline
5564
5565a. A bug that caused an extra newline to be printed when the cursor was on
5566 an otherwise empty line was fixed.
5567
5568b. An instance of memory being used after it was freed was corrected.
5569
5570c. The redisplay code now works when the prompt is longer than the screen
5571 width.
5572
5573d. `dump-macros' is now a bindable name, as it should have been all along.
5574
5575e. Non-printable characters are now expanded when displaying macros and
5576 their values.
5577
5578f. The `dump-variables' and `dump-macros' commands now output a leading
5579 newline if they're called as the result of a key sequence, rather
5580 than directly by an application.
5581
55823. New Features in Bash
5583
5584a. There is a new builtin array variable: GROUPS, the set of groups to which
5585 the user belongs. This is used by the test suite.
5586
55874. New Features in Readline
5588
5589a. If a key sequence bound to `universal-argument' is read while reading a
5590 numeric argument started with `universal-argument', it terminates the
5591 argument but is otherwise ignored. This provides a way to insert multiple
5592 instances of a digit string, and is how GNU emacs does it.
5593
5594------------------------------------------------------------------------------
ccc6cda3
JA
5595This document details the changes between this version, bash-2.0-release,
5596and the previous version, bash-2.0-beta3.
5597
55981. Changes to Bash
5599
5600a. Fix to the `getopts' builtin so that it does the right thing when a
5601 required option argument is not present.
5602
5603b. The completion code now updates the common prefix of matched names
5604 after FIGNORE processing is done, since any names that were removed
5605 may have changed the common prefix.
5606
5607c. Fixed a bug that made messages in MAILPATH entries not work correctly.
5608
5609d. Fixed a serious documentation error in the description of the new
5610 ${parameter:offset[:length]} expansion.
5611
5612e. Fixes to make parameter substring expansion ({$param:offset[:length]})
5613 work when within double quotes.
5614
5615f. Fixes to make ^A (CTLESC) survive an unquoted expansion of positional
5616 parameters.
5617
5618g. Corrected a misspelling of `unlimited' in the output of `ulimit'.
5619
5620h. Fixed a bug that caused executable scripts without a leading `#!' to
5621 occasionally pick up the wrong set of positional parameters.
5622
5623i. Linux systems now have a working `ulimit -v', using RLIMIT_AS.
5624
5625j. Updated config.guess so that many more machine types are recognized.
5626
5627k. Fixed a bug with backslash-quoted slashes in the ${param/pat[/sub]}
5628 expansion.
5629
5630l. If the shell is named `-su', and `-c command' is supplied, read and
5631 execute the login shell startup files even though the shell is not
5632 interactive. This is to support the `-' option to `su'.
5633
5634m. Fixed a bug that caused core dumps when the DEBUG trap was ignored
5635 with `trap "" DEBUG' and a shell function was subsequently executed.
5636
5637n. Fixed a bug that caused core dumps in the read builtin when IFS was
5638 set to the null string and the input had leading whitespace.
5639
56402. Changes to Readline
5641
5642a. Fixed a bug that caused a numeric argument of 1024 to be ignored when
5643 inserting text.
5644
5645b. Fixed the display code so that the numeric argument is displayed as it's
5646 being entered.
5647
5648c. Fixed the numeric argument reading code so that `M-- command' is
5649 equivalent to `M--1 command', as the prompt implies.
5650
56513. New Features in Bash
5652
5653a. `ulimit' now sets both hard and soft limits and reports the soft limit
5654 by default (when neither -H nor -S is specified). This is compatible
5655 with versions of sh and ksh that implement `ulimit'.
5656
5657b. Integer constants have been extended to base 64.
5658
56594. New Features in Readline
5660
5661a. The `home' and `end' keys are now bound to beginning-of-line and
5662 end-of-line, respectively, if the corresponding termcap capabilities
5663 are present.
5664
5665------------------------------------------------------------------------------
5666This document details the changes between this version, bash-2.0-beta3,
5667and the previous version, bash-2.0-beta2.
5668
56691. Changes to Bash
5670
5671a. System-specific changes for: AIX 4.2, SCO 3.2v[45], HP-UX.
5672
5673b. When in POSIX mode, variable assignments preceding a special builtin
5674 persist in the shell environment after the builtin completes.
5675
5676c. Changed all calls to getwd() to getcwd(). Improved check for systems
5677 where the libc getcwd() calls popen(), since that breaks on some
5678 systems when job control is being used.
5679
5680d. Fixed a bug that caused seg faults when executing scripts with the
5681 execute bit set but without a leading `#!'.
5682
5683e. The environment passed to executed commands is never sorted.
5684
5685f. A bug was fixed in the code that expands ${name[@]} to the number of
5686 elements in an array variable.
5687
5688g. A bug was fixed in the array compound assignment code ( A=( ... ) ).
5689
5690h. Window size changes now correctly propagate down to readline if
5691 the shopt `checkwinsize' option is enabled.
5692
5693i. A fix was made in the code that expands to the length of a variable
5694 value (${#var}).
5695
5696j. A fix was made to the command builtin so that it did not turn on the
5697 `no fork' flag inappropriately.
5698
5699k. A fix was made to make `set -n' work more reliably.
5700
5701l. A fix was made to the job control initialization code so that the
5702 terminal process group is set to the shell's process group if the
5703 shell changes its own process group.
5704
57052. Changes to Readline
5706
5707a. System-specific changes for: SCO 3.2v[45].
5708
5709b. The behavior of the vi-mode `.' when redoing an `i' command was changed
5710 to insert the text previously inserted by the `i' command rather than
5711 simply entering insert mode.
5712
57133. New features in Bash
5714
5715a. There is a new version of the autoload function package, in
5716 examples/functions/autoload.v2, that uses arrays and provides more
5717 functionality.
5718
5719b. Support for LC_COLLATE and locale-specific sorting of the results of
5720 pathname expansion if strcoll() is available.
5721
57224. New Features in Readline
5723
5724a. Support for locale-specific sorting of completion possibilities if
5725 strcoll() is available.
5726
5727------------------------------------------------------------------------------
5728This document details the changes between this version, bash-2.0-beta2,
5729and the previous version, bash-2.0-beta1.
5730
57311. Changes to Bash
5732
5733a. `pushd -' is once again equivalent to `pushd $OLDPWD'.
5734
5735b. OS-specific changes for: SCO 3.2v[45].
5736
5737c. A change was made to the fix for the recently-reported security hole
5738 when reading characters with octal value 255 to make it work better on
5739 systems with restartable system calls when not using readline.
5740
5741d. Some changes were made to the test suite so that it works if you
5742 configure bash with --enable-usg-echo-default.
5743
5744e. A fix was made to the parsing of conditional arithmetic expressions.
5745
5746f. Illegal arithmetic bases now cause an arithmetic evaluation error rather
5747 than being silently reset.
5748
5749g. Multiple arithmetic bases now cause an arithmetic evaluation error
5750 instead of being ignored.
5751
5752h. A fix was made to the evaluation of ${param?word} to conform to POSIX.2.
5753
5754i. A bug that sometimes caused array indices to be evaluated twice (which
5755 would cause errors when they contained assignment statements) was fixed.
5756
5757j. `ulimit' was rewritten to avoid problems with getrlimit(2) returning
5758 unsigned values and to simplify the code.
5759
5760k. A bug in the command-oriented-history code that caused it to sometimes
5761 put semicolons after right parens inappropriately was fixed.
5762
5763l. The values inserted into the prompt by the \w and \W escape sequences
5764 are now quoted to prevent further expansion.
5765
5766m. An interactive shell invoked as `sh' now reads and executes commands
5767 from the file named by $ENV when it starts up. If it's a login shell,
5768 it does this after reading /etc/profile and ~/.profile.
5769
5770n. The file named by $ENV is never read by non-interactive shells.
5771
57722. Changes to Readline
5773
5774a. A few changes were made to hide some macros and functions that should not
5775 be public.
5776
5777b. An off-by-one error that caused seg faults in the history expansion code
5778 was fixed.
5779
57803. New Features in Bash
5781
5782a. The ksh-style ((...)) arithmetic command was implemented. It is exactly
5783 identical to let "...". This is controlled by a new option to configure,
5784 `--enable-dparen-arithmetic', which is on by default.
5785
5786b. There is a new #define available in config.h.top: SYS_BASH_LOGOUT. If
5787 defined to a filename, bash reads and executes commands from that file
5788 when a login shell exits. It's commented out by default.
5789
5790c. `ulimit' has a `-l' option that reports the maximum amount of data that
5791 may be locked into memory on 4.4BSD-based systems.
5792
5793------------------------------------------------------------------------------
5794This document details the changes between this version, bash-2.0-beta1,
5795and the previous version, bash-2.0-alpha4.
5796
57971. Changes to Bash
5798
5799a. A bug that sometimes caused traps to be ignored on signals the
5800 shell treats specially was fixed.
5801
5802b. The internationalization code was changed to track the values of
5803 LC_* variables and call setlocale() as appropriate. The TEXTDOMAIN
5804 and TEXTDOMAINDIR variables are also tracked; changes cause calls
5805 to textdomain() and bindtextdomain(), if available.
5806
5807c. A bug was fixed that sometimes caused double-quoted strings to be
5808 parsed incorrectly.
5809
5810d. Changes were made so that the siglist code compiles correctly on
5811 Solaris 2.5.
5812
5813e. Added `:' to the set of characters that cause word breaks for the
5814 completion code so that pathnames in assignments to $PATH can be
5815 completed.
5816
5817f. The `select' command was fixed to print $PS3 to stderr.
5818
5819g. Fixed an error in the manual page section describing the effect that
5820 setting and unsetting GLOBIGNORE has on the setting of the `dotglob'
5821 option.
5822
5823h. The time conversion code now uses CLK_TCK rather than CLOCKS_PER_SEC
5824 on systems without gettimeofday() and resources.
5825
5826i. The getopt static variables are now initialized each time a subshell
5827 is started, so subshells using `getopts' work right.
5828
5829j. A sign-extension bug that caused a possible security hole was fixed.
5830
5831k. The parser now reads characters between backquotes within a double-
5832 quoted string as a single word, so double quotes in the backquoted
5833 string don't terminate the enclosing double-quoted string.
5834
5835l. A bug that caused `^O' to work incorrectly when typed as the first
5836 thing to an interactive shell was fixed.
5837
5838m. A rarely-exercised off-by-one error in the code that quotes variable
5839 values was fixed.
5840
5841n. Some memory and file descriptor leaks encountered when running a
5842 shell script that is executable but does not have a leading `#!'
5843 were plugged.
5844
58452. Changes to Readline
5846
5847a. A bug that sometimes caused incorrect results when trying to read
5848 typeahead on systems without FIONREAD was fixed.
5849
58503. New Features in Bash
5851
5852a. The command timing code now uses the value of the TIMEFORMAT variable
5853 to format and display timing statistics.
5854
5855b. The `time' reserved word now accepts a `-p' option to force the
5856 POSIX.2 output format.
5857
5858c. There are a couple of new and updated scripts to convert csh startup
5859 files to bash format.
5860
5861d. There is a new builtin array variable: BASH_VERSINFO. The various
5862 members hold the parts of the version information in BASH_VERSION,
5863 plus the value of MACHTYPE.
5864
58654. New Features in Readline
5866
5867a. Setting LANG to `en_US.ISO8859-1' now causes readline to enter
5868 eight-bit mode.
5869
5870------------------------------------------------------------------------------
5871This document details the changes between this version, bash-2.0-alpha4,
5872and the previous version, bash-2.0-alpha3.
5873
58741. Changes to Bash
5875
5876a. There is better detection of rsh connections on Solaris 2.
5877
5878b. Assignments to read-only variables preceding a command name are now
5879 variable assignment errors. Variable assignment errors cause
5880 non-interactive shells running in posix mode to exit.
5881
5882c. The word tokenizer was rewritten to handle nested quotes and pairs
5883 ('', "", ``, ${...}, $(...), $[...], $'...', $"...", <(...), >(...))
5884 correctly. Some of the parameter expansion code was updated as a
5885 consequence.
5886
5887d. A fix was made to `test' when given three arguments so that a binary
5888 operator is checked for first, before checking that the first argument
5889 is `!'.
5890
5891e. 2''>/dev/null is no longer equivalent to 2>/dev/null.
5892
5893f. Parser error messages were regularized, and in most cases the name of
5894 the shell script being read by a non-interactive shell is not printed
5895 twice.
5896
5897g. A fix was made to the completion code so that it no longer removes the
5898 text the user typed in some cases.
5899
5900h. The special glibc `getopt' environment variable is no longer put into
5901 the environment on machines with small values of ARG_MAX.
5902
5903i. The expansion of ${...} now follows the POSIX.2 rules for finding the
5904 closing `}'.
5905
5906j. The shell no longer displays spurious status messages for background
5907 jobs in shell scripts that complete successfully when the script is
5908 run from a terminal.
5909
5910k. `shopt -o' now correctly updates $SHELLOPTS.
5911
5912l. A bug that caused the $PATH searching code to return a non-executable
5913 file even when an executable file with the same name appeared later in
5914 $PATH was fixed.
5915
5916m. The shell now does tilde expansions on unquoted `:~' in assignment
5917 statements when not in posix mode.
5918
5919n. Variable assignment errors when a command consists only of assignments
5920 now cause non-interactive shells to exit when in posix mode.
5921
5922o. If the variable in a `for' or `select' command is read-only, or not a
5923 legal shell identifier, a variable assignment error occurs.
5924
5925p. `test' now handles `-a' and `-o' as binary operators when three arguments
5926 are supplied, and correctly parses `( word )' as equivalent to `word'.
5927
5928q. `test' was fixed so that file names of the form /dev/fd/NN mean the same
5929 thing on all systems, even Linux.
5930
5931r. Fixed a bug in the globbing code that caused patterns with multiple
5932 consecutive `*'s to not be matched correctly.
5933
5934s. Fixed a bug that caused $PS2 to not be printed when an interactive shell
5935 not using readline is reading a here document.
5936
5937t. Fixed a bug that caused history expansion to be performed inappropriately
5938 when a single-quoted string spanned more than one line.
5939
5940u. `getopts' now checks that the variable name passed by the user as the
5941 second argument is a legal shell identifier and that the variable is
5942 not read-only.
5943
5944v. Fixed `getopts' to obey POSIX.2 rules for setting $OPTIND when it
5945 encounters an error.
5946
5947w. Fixed `set' to display variable values in a form that can be re-read.
5948
5949x. Fixed a bug in the code that keeps track of whether or not local variables
5950 have been declared at the current level of function nesting.
5951
5952y. Non-interactive shells in posix mode now exit if the name in a function
5953 declaration is not a legal identifier.
5954
5955z. The job control code now ignores stopped children when the shell is not
5956 interactive.
5957
5958aa. The `cd' builtin no longer attempts spelling correction on the directory
5959 name if the shell is not interactive, regardless of the setting of the
5960 `cdspell' option.
5961
5962bb. Some OS-specific changes were made for SCO 3.2v[45] and AIX 4.2.
5963
5964cc. `time' now prints its output to stderr, as POSIX.2 specifies.
5965
59662. Fixes to Readline
5967
5968a. After printing possible completions, all lines of a multi-line prompt
5969 are redisplayed.
5970
5971b. Some changes were made to the terminal handling code in rltty.c to
5972 work around AIX 4.2 bugs.
5973
59743. New Features in Bash
5975
5976a. There is a new loadable builtin: sprintf, with calling syntax
5977 sprintf var format [args]
5978 This provides an easy way to simulate ksh left- and right-justified
5979 variable values.
5980
5981b. The expansions of \h and \H in prompt strings were swapped. \h now
5982 expands to the hostname up to the first `.', as in bash-1.14.
5983
59844. New Features in Readline
5985
5986a. The bash-1.14 behavior when ^M is typed while doing an incremental
5987 search was restored. ^J may now be used to terminate the search without
5988 accepting the line.
5989
5990b. There is a new bindable variable: disable-completion. This inhibits
5991 word completion and causes the completion character to be inserted as
5992 if it had been bound to self-insert.
5993
5994------------------------------------------------------------------------------
5995This document details the changes between this version, bash-2.0-alpha3,
5996and the previous version, bash-2.0-alpha2.
5997
5998There is now a file `COMPAT' included in the distribution that lists the
5999user-visible incompatibilities between 1.14 and 2.0.
6000
60011. Changes to Bash
6002
6003a. Some work was done so that word splitting of the rhs of assignment
6004 statements conforms more closely to historical practice.
6005
6006b. A couple of errant memory frees were fixed.
6007
6008c. A fix was made to the test builtin so it recognizes `<' and `>' as
6009 binary operators.
6010
6011d. The GNU malloc in lib/malloc/malloc.c now scrambles memory as it's
6012 allocated and freed. This is to catch callers that refer to freed
6013 memory or assume something about newly-allocated memory.
6014
6015e. Fixed a problem with conversion to 12-hour time in the prompt
6016 expansion code.
6017
6018f. Fixed a problem with configure's argument parsing order. Now you can
6019 correctly turn on specific options after using --enable-minimal-config.
6020
6021g. The configure script now automatically disables the use of GNU malloc
6022 on systems where it's appropriate (better than having people read the
6023 NOTES file and do it manually).
6024
6025h. There are new prompt expansions (\v and \V) to insert version information
6026 into the prompt strings.
6027
6028i. The default prompt string now includes the version number.
6029
6030j. Most of the builtins that take no options were changed to use the
6031 internal getopt so they can produce proper error messages for -?
6032 and incorrect options.
6033
6034k. Some system-specific changes were made for SVR4.2 and Solaris 2.5.
6035
6036l. Bash now uses PATH_MAX instead of MAXPATHLEN and NAME_MAX instead of
6037 MAXNAMLEN.
6038
6039m. A couple of problems caused by uninitialized variables were fixed.
6040
6041n. There are a number of new loadable builtin examples: logname, basename,
6042 dirname, tty, pathchk, tee, head, and rmdir. All of these conform to
6043 POSIX.2.
6044
6045o. Bash now notices changes in TZ and calls tzset() if present, so
6046 changing TZ will alter the time printed by prompt expansions.
6047
6048p. The source was reorganized a bit so I don't have to wait so long for
6049 some files to compile, and to facilitate the creation of a `shell
6050 library' at some future point.
6051
6052q. Bash no longer turns off job control if called as `sh', since the
6053 POSIX.2 spec includes job control as a standard feature.
6054
6055r. `bash -o posix' now works as intended.
6056
6057s. Fixed a problem with the completion code: when completing a filename
6058 that contained globbing characters, if show-all-if-ambiguous was set,
6059 the completion code would remove the user's text.
6060
6061t. Fixed ulimit so that (hopefully) the full range of limits is available
6062 on HPUX systems.
6063
6064u. A new `shopt' option (`hostcomplete') enables and disables hostname
6065 completion.
6066
6067v. The shell no longer attempts to save the history on an abort(),
6068 which is usually called by programming_error().
6069
6070w. The `-s' option to `fc' was changed to echo the command to be executed
6071 to stderr instead of stdout.
6072
6073x. If the editor invoked by `fc -e' exits with a non-zero status, no
6074 commands are executed.
6075
6076y. Fixed a bug that made the shopt `histverify' option work incorrectly.
6077
6078z. There is a new variable `MACHTYPE' whose value is the GNU-style
6079 `cpu-company-system' system description as set by configure. (The
6080 values of MACHTYPE and HOSTTYPE should really be swapped.)
6081
6082aa. The `ulimit' builtin now allows the maximum virtual memory size to be
6083 set via setrlimit(2) if RLIMIT_VMEM is defined.
6084
6085bb. `bash -nc 'command'' no longer runs `command'.
6086
60872. Changes to Readline
6088
6089a. Fixed a typo in the code that checked for FIONREAD in input.c.
6090
6091b. Fixed a bug in the code that outputs keybindings, so things like C-\
6092 are quoted properly.
6093
6094c. Fixed a bug in the inputrc file parsing code to handle the problems
6095 caused by inputrc files created from the output of `bind -p' in
6096 previous versions of bash. The problem was due to the bug fixed
6097 in item b above.
6098
6099d. Readline no longer turns off the terminal's meta key, and turns it on
6100 once the first time it's called.
6101
6102------------------------------------------------------------------------------
6103This file documents the changes between this version, bash-2.0-alpha2,
6104and the previous version, bash-2.0-alpha.
6105
61061. Changes to Bash
6107
6108a. The shell no longer thinks directories are executable.
6109
6110b. `disown' has a new option, `h', which inhibits the resending of SIGHUP
6111 but does not remove the job from the jobs table.
6112
6113c. The varargs functions in error.c now use ANSI-C `stdarg' if available.
6114
6115d. The build process now treats the `build version' in .build as local to
6116 the build directory, so different versions built from the same source
6117 tree have different `build versions'.
6118
6119e. Some problems with the grammar have been fixed. (It used `list' in a few
6120 productions where `compound_list' was needed. A `list' must be terminated
6121 with a newline or semicolon; a `compound_list' need not be.)
6122
6123f. A fix was made to keep `wait' from hanging when waiting for all background
6124 jobs.
6125
6126g. `bash --help' now writes its output to stdout, like the GNU Coding Standards
6127 specify, and includes the machine type (the value of MACHTYPE).
6128
6129h. `bash --version' now prints more information and exits successfully, like
6130 the GNU Coding Standards specify.
6131
6132i. The output of `time' and `times' now prints fractional seconds with three
6133 places after the decimal point.
6134
6135j. A bug that caused process substitutions to screw up the pipeline printed
6136 by `jobs' was fixed.
6137
6138k. Fixes were made to the code that implements $'...' and $"..." so they
6139 work as documented.
6140
6141l. The process substitution code now opens named pipes for reading with
6142 O_NONBLOCK to avoid hanging.
6143
6144m. Fixes were made to the trap code so the shell cleans up correctly if the
6145 trap command contains a `return' and we're executing a function or
6146 sourcing a script with `.'.
6147
6148n. Fixes to doc/Makefile.in so that it doesn't try to remake all of the
6149 documentation (ps, dvi, etc.) on a `make install'.
6150
6151o. Fixed an auto-increment error that caused bash -c args to sometimes dump
6152 core.
6153
6154p. Fixed a bug that caused $HISTIGNORE to fail when the history line
6155 contained globbing characters.
6156
61572. Changes to Readline
6158
6159a. There is a new string variable, rl_library_version, available for use by
6160 applications. The current value is "2.1".
6161
6162b. A bug encountered when expand-tilde was enabled and file completion was
6163 attempted on a word beginning with `~/' was fixed.
6164
6165c. A slight change was made to the incremental search termination behavior.
6166 ESC still terminates the search, but if input is pending or arrives
6167 within 0.1 seconds (on systems with select(2)), it is used as a prefix
6168 character. This is intented to allow users to terminate searches with
6169 the arrow keys and get the behavior they expect.