summaryrefslogtreecommitdiff
path: root/tests/read6.sub
blob: abfe89db23bda1f0402afccd0dd71acf17d78596 (plain)
1
2
3
4
5
6
7
8
9
10
# test read with a timeout of 0 -- input polling
# sleep with fractional seconds argument is not universal
echo abcde | { sleep 0.25 2>/dev/null ; read -t 0; }
echo $?

read -t 0 < $0
echo $?

read -t 0
echo $?