-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This bug was previously reported in att#37. Ksh ignores `-r` when `read -r -d` is run because when the bit for `D_FLAG` is set, the bit for `R_FLAG` is unset as a side effect of setting `D_FLAG`. The following set of commands fails to print a backslash: $ printf '\\\000' | read -r -d '' $ echo $REPLY The fix for this bug is to set `D_FLAG` with `D_FLAG + 1`, which prevents `R_FLAG` from being unset. This bugfix has been backported from ksh93v- 2013-10-10-alpha. src/cmd/ksh93/bltins/read.c: - Set `D_FLAG` with `D_FLAG + 1` to prevent the bit for `R_FLAG` from being unset. src/cmd/ksh93/tests/builtins.sh: - Add the regression test for `read -r -d` from ksh93v-.
- Loading branch information
Showing
4 changed files
with
14 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -17,4 +17,4 @@ | |
* David Korn <[email protected]> * | ||
* * | ||
***********************************************************************/ | ||
#define SH_RELEASE "93u+m 2020-06-15" | ||
#define SH_RELEASE "93u+m 2020-06-16" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters