projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a29a5e4
)
flush typeahead before prompt
author
Paul Fox
<pgf@brightstareng.com>
Wed, 7 Nov 2007 15:51:35 +0000
(15:51 -0000)
committer
Paul Fox
<pgf@brightstareng.com>
Wed, 7 Nov 2007 15:51:35 +0000
(15:51 -0000)
loginutils/login.c
patch
|
blob
|
history
diff --git
a/loginutils/login.c
b/loginutils/login.c
index ef27c3b4ac67a6f0eba740d63667d2c083e60c25..c1e0c769973dffcf518dbda4c34c7e5962997c11 100644
(file)
--- a/
loginutils/login.c
+++ b/
loginutils/login.c
@@
-305,6
+305,10
@@
int login_main(int argc, char **argv)
openlog(applet_name, LOG_PID | LOG_CONS | LOG_NOWAIT, LOG_AUTH);
while (1) {
+
+ /* flush away any type-ahead (as getty does) */
+ (void) ioctl(0, TCFLSH, TCIFLUSH);
+
if (!username[0])
get_username_or_die(username, sizeof(username));