Hi,

Please try to read a value from a file in an interactive shell.
Example:
--- cut here
echo test > tmp1
read < tmp1
echo $REPLY
--- cut here

Current result: hush exits before "echo $REPLY"
Expected result: hush prints "test" and prompts for next command

It seems that the redirection of stdin isn't cleaned up when command
finishes. Please have a look at following script:

--- cut here
echo before:
readlink /proc/self/fd/0 /proc/self/fd/1
: < /dev/null > /dev/null
echo after:
readlink /proc/self/fd/0 /proc/self/fd/1
--- cut here

and it's output in hush:

--- cut here
before:
/dev/pts/17
/dev/pts/17
after:
/dev/null
/dev/pts/17
--- cut here

Expected result is equal both "before" and "after".
Current result means that a script cannot continue to process data from
stdin if it had to grab some auxiliary data from somewhere else.

-- 

Attachment: redir_input.right
Description: Binary data

Attachment: redir_input.tests
Description: Binary data

_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox

Reply via email to