From: Alan Cox Date: Sun, 21 May 2017 21:50:28 +0000 (+0100) Subject: ed: fix bugs and warnings X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=b442431490623939c1aec376c6be37d23d37a8f6;p=FUZIX.git ed: fix bugs and warnings With this fixed it seems to be stable on M68K. --- 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--;