hush: fix IFS handling in read
authorDenys Vlasenko <vda.linux@googlemail.com>
Wed, 11 Apr 2018 15:18:34 +0000 (17:18 +0200)
committerDenys Vlasenko <vda.linux@googlemail.com>
Wed, 11 Apr 2018 15:18:34 +0000 (17:18 +0200)
commit44257ad5d0790a846423c9ef69a50049366b4578
tree8cb08256360770c85458b874e7489e5ba3183dd8
parent9678636911b39a7adf9b51d5b625cf4dc7e4ac81
hush: fix IFS handling in read

$ echo "X:Y:" | (IFS=": " read x y; echo "|$x|$y|")
|X|Y|
$ echo "X:Y  :  " | (IFS=": " read x y; echo "|$x|$y|")
|X|Y|

function                                             old     new   delta
shell_builtin_read                                  1320    1426    +106

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
shell/hush_test/hush-read/read_ifs2.right [new file with mode: 0644]
shell/hush_test/hush-read/read_ifs2.tests [new file with mode: 0755]
shell/shell_common.c