422 Commits

Author SHA1 Message Date
Chet Ramey 2d4ba0c618 fixed a bug with expanding unquoted $* when the separator is not whitespace and one or more of the positional parameters ends with the separator, resulting in an extra blank field being generated; fixed an issue with adjusting SHLVL in subshells that caused the environment to be rebuilt too many times; fix to make sure function substitution doesn't leave the -v option unset 2026-05-20 10:18:32 -04:00
Chet Ramey 669b32f676 interim fix for generic list functions to avoid pointer aliasing issues; documentation updates 2026-05-08 11:36:36 -04:00
Chet Ramey 55f721c51e update fix to save history if fatal signal arrives during $PROMPT_COMMAND execution; fix issue with extglob and empty patterns preceding pattern beginning with a `.' 2026-03-24 10:10:30 -04:00
Chet Ramey d0b41c2c5f fix cosmetic error when printing if commands containing here-documents in the body; compiling -DSTRICT_POSIX now forces posix-mode shells to expand redirections before assignment statements preceding simple commands 2026-03-03 11:14:10 -05:00
Chet Ramey 044c1acc91 fix posix-mode tilde expansion so non-assignment words containing "~:" do not undergo tilde expansion; heuristic to skip case statements while performing history expansion on $() command substitutions; undo redirections before running an EXIT trap when executing a builtin in a subshell 2026-02-17 13:08:27 -05:00
Chet Ramey a6421d8419 modify way bash avoids running traps in subshells that haven't reset the trap strings yet; new readline bindable command 'shell-expand-and-requote-line' 2026-01-14 11:08:22 -05:00
Chet Ramey e7c3acf108 change posix-mode implicit redirection from /dev/null for asynchronous commands so that 0<&0 does not count as an explicit redirection for austin-group interp 1913; fix spurious debug message about job notification for -c command; fix error handling for wait builtin if there are no children in a subshell 2026-01-06 10:46:14 -05:00
Chet Ramey a43e08df2d history builtin has a -H option to display history entries as they would be written to the history file; history builtin now takes a START-END range specifier for listing; fix stray semicolon when printing shell functions containing a case command; changes to stdin redirection detection in preparation for POSIX interp 1913 2026-01-05 11:57:18 -05:00
Chet Ramey 4b27601dfd fixes for several bugs found via fuzzing: overflow in $'...' hex expansion; fix for accessing freed memory when reading input from stdin and using multiple redirections to stdin; fix for pointer aliasing problem after a syntax error while executing a command string 2025-12-30 16:06:40 -05:00
Chet Ramey f27bf94a79 implementation of printf '%N$' numbered argument conversion specifier, compatible with coreutils 2025-12-05 15:50:38 -05:00
Chet Ramey 5a104e96d8 fix longjmp error when timing null command in posix mode; unset exit trap in subshells before checking for pending fatal signal; changes for gcc sometimes-uninitialized warning 2025-12-02 17:15:44 -05:00
Chet Ramey 2fd02c8387 fix for a trap on SIGINT restoring the default disposition in an asynchronous subshell; change cd exit status if -Pe supplied and the directory can't be changed; fix for compound associative array assignment if one of the expanded words unsets the array during word expansion; fixes for rare systems that don't have various defines and system calls 2025-11-17 14:50:43 -05:00
Chet Ramey c299f535be speedups for character processing in a multibyte locale when expanding $'...'; cosmetic fix for select command when read returns EOF; fix for a forced interactive shell running under emacs with a pipe for stdin; fix for local nameref variables with the same name as variables in a function's temporary environment; fix for x=y local -n x' not making x' visible as a local variable; turn off nameref attribute for local nameref variables converted to arrays 2025-10-27 10:42:10 -04:00
Chet Ramey 403b32faf6 round seconds in command timing information if precision is >= 0; fix for readline word boundaries when quoted command substitutions appear; remove nameref attribute when converting nameref variable into an array; change how help strings are written to builtins.c; change read builtin to update unwind-protect if the input string is reallocated; fix crash when an expansion on the rhs of an assignment statement unsets the variable on the lhs 2025-10-23 16:35:55 -04:00
Chet Ramey 6a48b39bba read builtin fixes for CHERI environment; use CLOCK_GETTIME in gettimeofday replacement; readline fix to not optimize typeahead while defining a keyboard macro; fix for crash with unset nameref variable; make sure to save currently executing command around running DEBUG trap 2025-10-14 14:21:00 -04:00
Chet Ramey f2f545ad7b fix for %P in TIMEFORMAT; make updating variables that aren't subject to allexport smoother; fix spurious compiler warning about realloc; efficiency improvement for command timing; fix issue with read builtin and failure to set terminal attributes 2025-10-06 15:29:41 -04:00
Chet Ramey 4f536430e4 fix problem with completing filenames with user-supplied double quotes containing word expansion characters; fix problem with printf %S and precision overflow; fix issue with %P in TIMEFORMAT when timing null commands in posix mode; fix problem with SIGINT while parsing command substitutions 2025-10-01 11:14:27 -04:00
Chet Ramey cf8a2518c8 fix for potential read builtin crash if bash gets a signal before read reads any input; make wait -f work if there are no pid or job arguments and update documentation; save and restore variable reflected in $BASH_COMMAND around shell function calls 2025-09-18 17:54:55 -04:00
Chet Ramey b88cd1c366 experimental change to use groff instead of man2html for HTML man pages; man page updates for reserved words; fix for pattern matching bracket expression ranges; readline changes to disallow defining some recursive keyboard macros 2025-09-18 17:26:51 -04:00
Chet Ramey a451bfc3f5 declare builtin changes to reject -i when used with -n; readline changes to make control characters visible in search strings; readline signal handling changes to avoid data corruption and UAF; documentation updates for more consistent quoting 2025-09-04 12:29:57 -04:00
Chet Ramey 0864568359 fix for nofork comsubs undoing enclosing command's redirections; fix for binding _ variable in the temporary environment; fix for crash when making special variables arrays; accommodate IFS as array variable; fix for SIGINT arriving while cleaning up a readline incremental search 2025-08-20 11:08:28 -04:00
Chet Ramey 3160c0b89c fix issue with break in nofork comsub when expanding for command word list; add error message if the value of a nameref variable expands to an invalid variable name 2025-08-14 10:27:52 -04:00
Chet Ramey e9053f2a3a fix for parameter expansions that contain valid and invalid expansions; avoid stale readdir() value in getcwd replacement; check libtinfow for termcap functions; fix to propagate exit status of builtins run in subshells back to calling shell 2025-08-04 10:18:32 -04:00
Chet Ramey 727b8d3663 addition to POSIX mode documentation; new translations; update copyrights on some files; update formatted documentation; changes to cut/lcut loadable builtins when supplied -a ARRAY 2025-06-06 12:16:11 -04:00
Chet Ramey 535a8150b6 fix for command substitution string parsing that resulted in top-level unwind-protects being run in the wrong spot; fix for delimiter byte being part of invalid multibyte character in read builtin 2025-05-04 17:21:25 -04:00
Chet Ramey e009d30dff fix for invalid brace sequence expressions; cosmetic fix to help builtin; documentation and copyright updates; bump version to bash-5.3-rc1; cosmetic locale fixes 2025-03-24 17:07:43 -04:00
Chet Ramey c3997d51f8 documentation updates for arithmetic expansion and array subscripts; update BASH_COMMAND for subshells; fix potential file descriptor leak in here document pipes 2025-03-07 10:23:58 -05:00
Chet Ramey c3ca11424d fix issue with redirections to bash input file descriptor; new minimal chmod builtin; posix mode change for kill builtin return status; perform additional validation on brace expansion sequence expressions 2025-02-12 11:18:16 -05:00
Chet Ramey 0390b4354a posix change for undoing redirections after failed exec; change readline to set lines and columns after SIGTSTP/SIGCONT 2025-01-28 10:15:16 -05:00
Chet Ramey 22417e7881 new readline command `export-completions'; update documentation; update translations with new strings; Makefile updates 2024-11-21 10:31:38 -05:00
Chet Ramey ee3b91dfd9 do not require leading . for rl color prefix etension; fix for isearch in single-byte locales; next set of doc updates (SIGNALS); add warning for invalid job id; allow function names to be non-identifiers in posix mode 2024-10-26 12:39:17 -04:00
Chet Ramey 254081c097 fix for set -e and compound commands inverting return status; tty fix for fg' from a key binding; posix mode wait -n' can return notified jobs; off-by-one error in history word tokenization; new configure option to set bash_source_fullpath 2024-09-27 12:00:46 -04:00
Chet Ramey bc5ddc8698 wait -n' notifies on a job it returns; in posix mode, wait' defers notification on a reaped pid unless the shell is interactive, as posix now specifies 2024-09-11 15:54:24 -04:00
Chet Ramey 2610d40b32 documentation updates; fix for null commands with redirection expansion errors; changes to job notifications for interactive shells sourcing files; fix underflow issue with word_top 2024-08-28 11:42:10 -04:00
Chet Ramey e327891b52 fix for printf with broken strtold; fix readline reading specified number of multibyte characters; fix read builtin to deal with invalid utf-8 continuation character as delimiter; turn off -n if supplied at interactive shell invocation 2024-08-21 16:11:01 -04:00
Chet Ramey cf694865de optimize asynchronous function invocations; fix for running return from trap while sourcing a file; restore completion function if read -e is interrupted 2024-08-15 16:37:54 -04:00
Chet Ramey e45ec6f76b new bash_source_fullpath shell option; documentation updates for wait builtin 2024-07-30 11:18:17 -04:00
Chet Ramey d3e86e66ce reap and store status of process substitutions even when there are no jobs; fix issue with optimizing shell functions that set RETURN trap; fix issue with procsubs and eval allowing '<file'; fix for fignore and ignorning completions 2024-07-11 12:03:23 -04:00
Chet Ramey dbff8b786e updates for several readline examples; update examples in readline documentation; update documentation for --rcfile option 2024-07-02 14:34:40 -04:00
Chet Ramey f65ed506d4 fix issue with interupting timed functions; fix for parsing comsubs inside arith for commands; allow break and continue inside arith for expressions; fix for case-insensitive completion with multibyte chars; fix some minor memory leaks; reset read buffer if it returns partial results on EINTR; fix for undo in execute-named-command 2024-06-03 09:09:11 -04:00
Chet Ramey 9cea457aef fix minor errors uncovered by address sanitizer; work around android issue with read -e -u; fix minor memory leaks; make spell-correct-shellword work with negative arguments; fix readline change-case on invalid multibyte character 2024-05-28 09:19:03 -04:00
Chet Ramey b3d8c8a4e7 change some error messages so the format string isn't the return value from gettext(); work around macos problem with gettext() in child processes; don't try to set tty state while running a trap; don't default to trying enable -f file if the shell is restricted; note that configure now supports --enable-year2038 2024-05-13 11:36:34 -04:00
Chet Ramey 6fb61ee126 allow some job notifications while running $PROMPT_COMMAND; allow notifications while running bind -x commands; change some translated messages to be more uniform 2024-05-06 11:25:35 -04:00
Chet Ramey d17d185fff fix for crash without arrays built in; allow some job status changes while the jobs list is frozen; change format for interactive shell terminated job notifications; allow some job notifications while running traps 2024-05-06 11:15:17 -04:00
Chet Ramey e6795c05dd fix coproc code to close previous coproc file descriptors if another one is created; start at setting additional coproc states; change release status to bash-5.3-alpha 2024-04-06 16:06:11 -04:00
Chet Ramey 03c8c43b79 man page typesetting updates for compatibilityand layout issues 2024-04-05 09:03:52 -04:00
Chet Ramey 6bd75b8d63 performance improvements for large history lists; fix problem with not unwind-protecting current command and name while executing 2024-02-14 09:43:03 -05:00
Chet Ramey dc97ded434 fix nofork comsub overwriting currently executing command; free readline undo list on signal in callback mode; avoid disabling readonly when assigning variables from the environment; fix bug with shell-expand-line and $'...' quoting inside command substitutions; add `bash-vi-complete' as bindable command name 2024-02-09 10:30:02 -05:00
Chet Ramey aa2d23cfac fix history expansion to not perform quick substitution on a new line that's part of a quoted string; save the value of $_ around prompt string decoding 2023-12-19 09:56:34 -05:00
Chet Ramey 9702b74a28 test suite fixes for some locales; fix to make bind -x bindings work with negative arguments; several portability fixes from pkgsrc; fixes for funsubs with return builtin state and local OPTIND 2023-12-04 16:14:53 -05:00