From b442431490623939c1aec376c6be37d23d37a8f6 Mon Sep 17 00:00:00 2001 From: Alan Cox Date: Sun, 21 May 2017 22:50:28 +0100 Subject: [PATCH] ed: fix bugs and warnings With this fixed it seems to be stable on M68K. --- Applications/util/ed.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Applications/util/ed.c b/Applications/util/ed.c index 9ad4bb15..c33dd5f2 100644 --- a/Applications/util/ed.c +++ b/Applications/util/ed.c @@ -134,7 +134,7 @@ static void docommands(void) cp = buf; while (isblank(*cp)) - *cp++; + cp++; have1 = FALSE; have2 = FALSE; @@ -468,7 +468,7 @@ static void subcommand(char *cp, NUM num1, NUM num2) printlines(num1, num1, FALSE); needprint = FALSE; } - lp = nlp->next; + lp = lp->next; num1++; continue; } @@ -926,7 +926,7 @@ static BOOL printlines(NUM num1, NUM num2, BOOL expandflag) * Show control characters and characters with the * high bit set specially. */ - cp = lp->data; + cp = (unsigned char *)lp->data; count = lp->len; if ((count > 0) && (cp[count - 1] == '\n')) count--; -- 2.34.1