[hackers] [sbase][ed] Cleanup scroll() (z)

From: Quentin Rameau <quinq_AT_fifth.space>
Date: Sun, 13 Dec 2015 14:48:33 +0100

last wasn't used and there's no real need to have an intermediary
boundary there.
---
 ed.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/ed.c b/ed.c
index ea61fe1..30709f4 100644
--- a/ed.c
+++ b/ed.c
_AT_@ -719,12 +719,11 @@ join(void)
 static void
 scroll(int num)
 {
-	int i, last;
+	int i;
 
 	if (!line1 || line1 == lastln)
 		error("incorrect address");
 
-	last = (line1 + num > lastln) ? lastln - line1 : num;
 	for (i = line1; i <= line1 + num && i <= lastln; ++i)
 		fputs(gettxt(i), stdout);
 	curln = i;
-- 
2.6.4
Received on Sun Dec 13 2015 - 14:48:33 CET

This archive was generated by hypermail 2.3.0 : Sun Dec 13 2015 - 15:00:18 CET