summaryrefslogtreecommitdiff
path: root/common/menu.c
diff options
context:
space:
mode:
authorHeiko Schocher <hs@denx.de>2012-01-16 21:13:05 +0000
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2012-02-12 10:11:23 +0100
commit9c3483113de1204118a1b252bf4c81b899dd12b4 (patch)
tree5f7af1ceb46bd36f92f63076081174db1d84bb96 /common/menu.c
parent2627c8c0a1bc64099cf6b6e2d978d666f88ef08d (diff)
downloadu-boot-imx-9c3483113de1204118a1b252bf4c81b899dd12b4.zip
u-boot-imx-9c3483113de1204118a1b252bf4c81b899dd12b4.tar.gz
u-boot-imx-9c3483113de1204118a1b252bf4c81b899dd12b4.tar.bz2
common: add possibility for readline_into_buffer timeout
add possibility to add a timeout when reading a line into a buffer. Signed-off-by: Heiko Schocher <hs@denx.de> Cc: Mike Frysinger <vapier@gentoo.org> Acked-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'common/menu.c')
-rw-r--r--common/menu.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/common/menu.c b/common/menu.c
index 5e0817c..3b1e0d0 100644
--- a/common/menu.c
+++ b/common/menu.c
@@ -222,7 +222,8 @@ static inline int menu_interactive_choice(struct menu *m, void **choice)
menu_display(m);
- readret = readline_into_buffer("Enter choice: ", cbuf);
+ readret = readline_into_buffer("Enter choice: ", cbuf,
+ m->timeout);
if (readret >= 0) {
choice_item = menu_item_by_key(m, cbuf);