From 083e74597613d2edd1d17fce1bca282a8db0f315 Mon Sep 17 00:00:00 2001 From: Hanif Bin Ariffin Date: Sat, 12 Jun 2021 20:34:21 +0800 Subject: [PATCH] Simplified page down implementation Signed-off-by: Hanif Bin Ariffin --- src/uu/more/src/more.rs | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/uu/more/src/more.rs b/src/uu/more/src/more.rs index 93a2f0edf..d7fba5080 100644 --- a/src/uu/more/src/more.rs +++ b/src/uu/more/src/more.rs @@ -297,10 +297,7 @@ impl<'a> Pager<'a> { } fn page_down(&mut self) { - self.upper_mark = self - .upper_mark - .saturating_add(self.content_rows.into()) - .min(self.line_count.saturating_sub(self.content_rows.into())); + self.upper_mark = self.upper_mark.saturating_add(self.content_rows.into()); } fn page_up(&mut self) {