aboutsummaryrefslogtreecommitdiff
path: root/paludis/util/system_TEST_setup.sh
diff options
context:
space:
mode:
Diffstat (limited to 'paludis/util/system_TEST_setup.sh')
-rwxr-xr-xpaludis/util/system_TEST_setup.sh10
1 files changed, 5 insertions, 5 deletions
diff --git a/paludis/util/system_TEST_setup.sh b/paludis/util/system_TEST_setup.sh
index 5bdc42a..7bee967 100755
--- a/paludis/util/system_TEST_setup.sh
+++ b/paludis/util/system_TEST_setup.sh
@@ -10,7 +10,7 @@ cat <<'END' > pipe_test.bash
echo "$1" | tr "\n" "\0" 1>&$PALUDIS_PIPE_COMMAND_WRITE_FD
response1=
while true ; do
- c=$(head -c1 <&$PALUDIS_PIPE_COMMAND_READ_FD )
+ read -n 1 -u $PALUDIS_PIPE_COMMAND_READ_FD c
[[ "$c" == $'\0' ]] && break
response1="${response1}${c}"
done
@@ -18,7 +18,7 @@ done
echo "$2" | tr "\n" "\0" 1>&$PALUDIS_PIPE_COMMAND_WRITE_FD
response2=
while true ; do
- c=$(head -c1 <&$PALUDIS_PIPE_COMMAND_READ_FD )
+ read -n 1 -u $PALUDIS_PIPE_COMMAND_READ_FD c
[[ "$c" == $'\0' ]] && break
response2="${response2}${c}"
done
@@ -32,7 +32,7 @@ cat <<'END' > captured_pipe_test.bash
echo "$1" | tr "\n" "\0" 1>&$PALUDIS_PIPE_COMMAND_WRITE_FD
response1=
while true ; do
- c=$(head -c1 <&$PALUDIS_PIPE_COMMAND_READ_FD )
+ read -n 1 -u $PALUDIS_PIPE_COMMAND_READ_FD c
[[ "$c" == $'\0' ]] && break
response1="${response1}${c}"
done
@@ -40,7 +40,7 @@ done
echo "$2" | tr "\n" "\0" 1>&$PALUDIS_PIPE_COMMAND_WRITE_FD
response2=
while true ; do
- c=$(head -c1 <&$PALUDIS_PIPE_COMMAND_READ_FD )
+ read -n 1 -u $PALUDIS_PIPE_COMMAND_READ_FD c
[[ "$c" == $'\0' ]] && break
response2="${response2}${c}"
done
@@ -48,7 +48,7 @@ done
echo "$3" | tr "\n" "\0" 1>&$PALUDIS_PIPE_COMMAND_WRITE_FD
response3=
while true ; do
- c=$(head -c1 <&$PALUDIS_PIPE_COMMAND_READ_FD )
+ read -n 1 -u $PALUDIS_PIPE_COMMAND_READ_FD c
[[ "$c" == $'\0' ]] && break
response3="${response3}${c}"
done