| @@ -132,7 +132,6 @@ int utf8_in2(int *c, const char *buf, int backwards) | |||
| int c1; | |||
| int n_bytes; | |||
| int ix; | |||
| static const unsigned char mask[4] = { 0xff, 0x1f, 0x0f, 0x07 }; | |||
| // find the start of the next/previous character | |||
| @@ -155,6 +154,7 @@ int utf8_in2(int *c, const char *buf, int backwards) | |||
| n_bytes = 3; | |||
| c1 &= mask[n_bytes]; | |||
| int ix; | |||
| for (ix = 0; ix < n_bytes; ix++) | |||
| { | |||
| if (!*buf) | |||
| @@ -290,10 +290,10 @@ int Read4Bytes(FILE *f) | |||
| { | |||
| // Read 4 bytes (least significant first) into a word | |||
| int ix; | |||
| unsigned char c; | |||
| int acc = 0; | |||
| for (ix = 0; ix < 4; ix++) { | |||
| unsigned char c; | |||
| c = fgetc(f) & 0xff; | |||
| acc += (c << (ix*8)); | |||
| } | |||