diff options
Diffstat (limited to 'crc32.c')
-rw-r--r-- | crc32.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -45,7 +45,7 @@ local void make_crc_table() | |||
45 | int n, k; | 45 | int n, k; |
46 | uLong poly; /* polynomial exclusive-or pattern */ | 46 | uLong poly; /* polynomial exclusive-or pattern */ |
47 | /* terms of polynomial defining this crc (except x^32): */ | 47 | /* terms of polynomial defining this crc (except x^32): */ |
48 | static Byte p[] = {0,1,2,4,5,7,8,10,11,12,16,22,23,26}; | 48 | static const Byte p[] = {0,1,2,4,5,7,8,10,11,12,16,22,23,26}; |
49 | 49 | ||
50 | /* make exclusive-or pattern from polynomial (0xedb88320L) */ | 50 | /* make exclusive-or pattern from polynomial (0xedb88320L) */ |
51 | poly = 0L; | 51 | poly = 0L; |
@@ -65,7 +65,7 @@ local void make_crc_table() | |||
65 | /* ======================================================================== | 65 | /* ======================================================================== |
66 | * Table of CRC-32's of all single-byte values (made by make_crc_table) | 66 | * Table of CRC-32's of all single-byte values (made by make_crc_table) |
67 | */ | 67 | */ |
68 | local uLongf crc_table[256] = { | 68 | local const uLongf crc_table[256] = { |
69 | 0x00000000L, 0x77073096L, 0xee0e612cL, 0x990951baL, 0x076dc419L, | 69 | 0x00000000L, 0x77073096L, 0xee0e612cL, 0x990951baL, 0x076dc419L, |
70 | 0x706af48fL, 0xe963a535L, 0x9e6495a3L, 0x0edb8832L, 0x79dcb8a4L, | 70 | 0x706af48fL, 0xe963a535L, 0x9e6495a3L, 0x0edb8832L, 0x79dcb8a4L, |
71 | 0xe0d5e91eL, 0x97d2d988L, 0x09b64c2bL, 0x7eb17cbdL, 0xe7b82d07L, | 71 | 0xe0d5e91eL, 0x97d2d988L, 0x09b64c2bL, 0x7eb17cbdL, 0xe7b82d07L, |
@@ -124,12 +124,12 @@ local uLongf crc_table[256] = { | |||
124 | /* ========================================================================= | 124 | /* ========================================================================= |
125 | * This function can be used by asm versions of crc32() | 125 | * This function can be used by asm versions of crc32() |
126 | */ | 126 | */ |
127 | uLongf * EXPORT get_crc_table() | 127 | const uLongf * EXPORT get_crc_table() |
128 | { | 128 | { |
129 | #ifdef DYNAMIC_CRC_TABLE | 129 | #ifdef DYNAMIC_CRC_TABLE |
130 | if (crc_table_empty) make_crc_table(); | 130 | if (crc_table_empty) make_crc_table(); |
131 | #endif | 131 | #endif |
132 | return (uLongf *)crc_table; | 132 | return (const uLongf *)crc_table; |
133 | } | 133 | } |
134 | 134 | ||
135 | /* ========================================================================= */ | 135 | /* ========================================================================= */ |