Path: blob/main/archivers/lha/files/patch-crcio.c
16147 views
--- src/crcio.c.orig 2000-10-04 14:57:38 UTC1+++ src/crcio.c2@@ -66,8 +66,7 @@ calccrc(p, n)34/* ------------------------------------------------------------------------ */5void6-fillbuf(n) /* Shift bitbuf n bits left, read n bits */7- unsigned char n;8+fillbuf(unsigned char n) /* Shift bitbuf n bits left, read n bits */9{10while (n > bitcount) {11n -= bitcount;12@@ -87,8 +86,7 @@ fillbuf(n) /* Shift bitbuf n bits left1314/* ------------------------------------------------------------------------ */15unsigned short16-getbits(n)17- unsigned char n;18+getbits(unsigned char n)19{20unsigned short x;2122@@ -99,9 +97,7 @@ getbits(n)2324/* ------------------------------------------------------------------------ */25void26-putcode(n, x) /* Write rightmost n bits of x */27- unsigned char n;28- unsigned short x;29+putcode(unsigned char n, unsigned short x) /* Write rightmost n bits of x */30{31while (n >= bitcount) {32n -= bitcount;33@@ -126,9 +122,7 @@ putcode(n, x) /* Write rightmost n bit3435/* ------------------------------------------------------------------------ */36void37-putbits(n, x) /* Write rightmost n bits of x */38- unsigned char n;39- unsigned short x;40+putbits(unsigned char n, unsigned short x) /* Write rightmost n bits of x */41{42x <<= USHRT_BIT - n;43while (n >= bitcount) {44@@ -308,7 +302,7 @@ fread_txt(p, n, fp)45c = '\r';46}47#ifdef EUC48- else if (euc_mode && (c == 0x8E || 0xA0 < c && c < 0xFF)) {49+ else if (euc_mode && (c == 0x8E || (0xA0 < c && c < 0xFF))) {50int d = fgetc(fp);51if (d == EOF) {52*p++ = c;535455