From ae1a9e899e0d4695834e8ce7348d41663abcef1e Mon Sep 17 00:00:00 2001 From: Ron Yorston Date: Tue, 21 Jul 2015 20:12:31 +0100 Subject: less: fix numeric input Signed-off-by: Ron Yorston Signed-off-by: Denys Vlasenko --- miscutils/less.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'miscutils/less.c') diff --git a/miscutils/less.c b/miscutils/less.c index dd932c5ed..4cdfa3bbb 100644 --- a/miscutils/less.c +++ b/miscutils/less.c @@ -1314,7 +1314,7 @@ static void number_process(int first_digit) i = 1; while (i < sizeof(num_input)-1) { keypress = less_getch(i + 1); - if ((unsigned)keypress > 255 || !isdigit(num_input[i])) + if ((unsigned)keypress > 255 || !isdigit(keypress)) break; num_input[i] = keypress; bb_putchar(keypress); -- cgit v1.2.3