mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-02 14:01:20 -03:00
Fix incorrect error on read with 1-character input
When `read` is given a single character of input (including the newline), it was bailing as if it had been given no input. This is incorrect.
This commit is contained in:
@@ -38,6 +38,8 @@ echo 'test' | read -l one two three
|
||||
print_vars one two three
|
||||
echo 'foo bar baz' | read -l one two three
|
||||
print_vars one two three
|
||||
echo -n 'a' | read -l one
|
||||
echo "$status $one"
|
||||
|
||||
echo
|
||||
set -l IFS
|
||||
|
||||
@@ -17,6 +17,7 @@ two
|
||||
1 '' 1 ''
|
||||
1 'test' 1 '' 1 ''
|
||||
1 'foo' 1 'bar' 1 ' baz'
|
||||
0 a
|
||||
|
||||
1 'hello'
|
||||
1 'h' 1 'ello'
|
||||
|
||||
Reference in New Issue
Block a user