diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2007-11-06 03:05:54 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2007-11-06 03:05:54 +0000 |
commit | 6bef3d1d2216234454875052220ca0f477a820b4 (patch) | |
tree | 717060345370b781d3d1cde7ab4dd29304a066e8 /editors | |
parent | 1bec1b980e3cf5ad604fb0c2038a3ab83d9ab5f5 (diff) |
fbset: fix buglet where we were using wrong pointer
readahead: stop using stdio.h
*: style fixes
Diffstat (limited to 'editors')
-rw-r--r-- | editors/diff.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/editors/diff.c b/editors/diff.c index c158c8763..64b7daa11 100644 --- a/editors/diff.c +++ b/editors/diff.c @@ -588,7 +588,9 @@ static void check(FILE * f1, FILE * f2) while (1) { ctold++; ctnew++; - if ((c = getc(f1)) != (d = getc(f2))) { + c = getc(f1); + d = getc(f2); + if (c != d) { J[i] = 0; if (c != '\n' && c != EOF) ctold += skipline(f1); @@ -668,7 +670,8 @@ static void fetch(long *f, int a, int b, FILE * lb, int ch) } col = 0; for (j = 0, lastc = '\0'; j < nc; j++, lastc = c) { - if ((c = getc(lb)) == EOF) { + c = getc(lb); + if (c == EOF) { printf("\n\\ No newline at end of file\n"); return; } |