tr: fix signed/unsigned warnings

This commit is contained in:
Hiltjo Posthuma 2015-01-10 17:38:28 +01:00 committed by sin
parent 1f3345b9e6
commit cf714e6edb

6
tr.c
View File

@ -52,8 +52,7 @@ rangelen(struct range r)
static size_t static size_t
setlen(struct range *set, size_t setranges) setlen(struct range *set, size_t setranges)
{ {
int i; size_t len = 0, i;
size_t len = 0;
for (i = 0; i < setranges; i++) for (i = 0; i < setranges; i++)
len += rangelen(set[i]); len += rangelen(set[i]);
@ -175,8 +174,7 @@ int
main(int argc, char *argv[]) main(int argc, char *argv[])
{ {
Rune r = 0, lastrune = 0; Rune r = 0, lastrune = 0;
int i, m; size_t off1, off2, m, i;
size_t off1, off2;
ARGBEGIN { ARGBEGIN {
case 'c': case 'c':