diff options
author | Rob Landley | 2005-12-12 07:02:15 +0000 |
---|---|---|
committer | Rob Landley | 2005-12-12 07:02:15 +0000 |
commit | e422af6bcb15a92b7eba3da5b5cf1bcc8c0b5f5c (patch) | |
tree | ad7641253fcdbbf74c534d35b227ac5ea347a733 | |
parent | a75c180e538bb8adc0bb280c61dd933fd8d3e56d (diff) | |
download | busybox-e422af6bcb15a92b7eba3da5b5cf1bcc8c0b5f5c.zip busybox-e422af6bcb15a92b7eba3da5b5cf1bcc8c0b5f5c.tar.gz |
Flush input when prompting for a password (bug 373).
-rw-r--r-- | libbb/bb_askpass.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libbb/bb_askpass.c b/libbb/bb_askpass.c index 1ae1520..42ccd66 100644 --- a/libbb/bb_askpass.c +++ b/libbb/bb_askpass.c @@ -44,6 +44,7 @@ char *bb_askpass(int timeout, const char * prompt) static char passwd[PWD_BUFFER_SIZE]; tcgetattr(STDIN_FILENO, &old); + tcflush(STDIN_FILENO, TCIFLUSH); size = sizeof(passwd); ret = passwd; |