|
Description |
the current implementation of "read -t" in ash doesn't match what other standard shells do. it seems to wait for the first character to be available, in raw mode, rather than waiting for fully-formed user input to be available, in cooked mode. i.e. normally if you type "hello<CR>" at a "read -t 5 foo" command, then unless you type the <CR> before 5 seconds has passed, $foo won't get anything at all (using bash). that's not what the commited code does -- if you type anything at all, it decides you'll be finishing, and waits forever.
this patch reimplements -t and and implements -n in a bash-compatible way. the config option name has been changed from CONFIG_ASH_TIMEOUT to CONFIG_ASH_READ_TIMEOUT and CONFIG_ASH_READ_NCHARS.
diff is against svn. |