diff options
author | Ray Lai <ray@cvs.openbsd.org> | 2006-05-10 01:10:24 +0000 |
---|---|---|
committer | Ray Lai <ray@cvs.openbsd.org> | 2006-05-10 01:10:24 +0000 |
commit | 09e2dd50c585446781b6e69a8ea1b145596c9289 (patch) | |
tree | fe97c8482796faa5c00301fec6299e027e7136d7 /usr.bin/rcs/diff.c | |
parent | f85300c7d45262d8c0e442737282d53880483ec9 (diff) |
Remove (size_t) casts on integer constants.
We should not cover up lint's shortcomings, especially if they no
longer exist.
``This is definately good.'' niallo@.
Diffstat (limited to 'usr.bin/rcs/diff.c')
-rw-r--r-- | usr.bin/rcs/diff.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/usr.bin/rcs/diff.c b/usr.bin/rcs/diff.c index c78b33fe05f..5bd36c76d40 100644 --- a/usr.bin/rcs/diff.c +++ b/usr.bin/rcs/diff.c @@ -1,4 +1,4 @@ -/* $OpenBSD: diff.c,v 1.4 2006/05/05 15:47:36 xsa Exp $ */ +/* $OpenBSD: diff.c,v 1.5 2006/05/10 01:10:23 ray Exp $ */ /* * Copyright (C) Caldera International Inc. 2001-2002. * All rights reserved. @@ -409,8 +409,8 @@ files_differ(FILE *f1, FILE *f2) if (stb1.st_size != stb2.st_size) return (1); for (;;) { - i = fread(buf1, (size_t)1, sizeof(buf1), f1); - j = fread(buf2, (size_t)1, sizeof(buf2), f2); + i = fread(buf1, 1, sizeof(buf1), f1); + j = fread(buf2, 1, sizeof(buf2), f2); if (i != j) return (1); if (i == 0 && j == 0) { @@ -868,7 +868,7 @@ ignoreline(char *line) { int ret; - ret = regexec(&ignore_re, line, (size_t)0, NULL, 0); + ret = regexec(&ignore_re, line, 0, NULL, 0); xfree(line); return (ret == 0); /* if it matched, it should be ignored. */ } @@ -1154,7 +1154,7 @@ asciifile(FILE *f) return (1); rewind(f); - cnt = fread(buf, (size_t)1, sizeof(buf), f); + cnt = fread(buf, 1, sizeof(buf), f); for (i = 0; i < cnt; i++) if (!isprint(buf[i]) && !isspace(buf[i])) return (0); @@ -1175,7 +1175,7 @@ match_function(const long *f, int pos, FILE *fp) nc = f[pos] - f[pos - 1]; if (nc >= sizeof(buf)) nc = sizeof(buf) - 1; - nc = fread(buf, (size_t)1, nc, fp); + nc = fread(buf, 1, nc, fp); if (nc > 0) { buf[nc] = '\0'; p = strchr((const char *)buf, '\n'); |