diff --git a/src/lib/util/chd.cpp b/src/lib/util/chd.cpp index 0db64344861..dc7c334b1bf 100644 --- a/src/lib/util/chd.cpp +++ b/src/lib/util/chd.cpp @@ -885,7 +885,7 @@ chd_error chd_file::read_hunk(uint32_t hunknum, void *buffer) // get a pointer to the map entry uint64_t blockoffs; uint32_t blocklen; - uint32_t blockcrc; + util::crc32_t blockcrc; uint8_t *rawmap; uint8_t *dest = reinterpret_cast(buffer); switch (m_version) @@ -2147,12 +2147,12 @@ void chd_file::decompress_v5_map() // read the reader uint8_t rawbuf[16]; file_read(m_mapoffset, rawbuf, sizeof(rawbuf)); - uint32_t mapbytes = be_read(&rawbuf[0], 4); - uint64_t firstoffs = be_read(&rawbuf[4], 6); - uint16_t mapcrc = be_read(&rawbuf[10], 2); - uint8_t lengthbits = rawbuf[12]; - uint8_t selfbits = rawbuf[13]; - uint8_t parentbits = rawbuf[14]; + uint32_t const mapbytes = be_read(&rawbuf[0], 4); + uint64_t const firstoffs = be_read(&rawbuf[4], 6); + util::crc16_t const mapcrc = be_read(&rawbuf[10], 2); + uint8_t const lengthbits = rawbuf[12]; + uint8_t const selfbits = rawbuf[13]; + uint8_t const parentbits = rawbuf[14]; // now read the map std::vector compressed(mapbytes);