Networking: silence compiler warnings

This commit is contained in:
Carter Li
2025-03-16 09:43:08 +08:00
parent 2ce511c4d3
commit dfc9bc265c
+1 -1
View File
@@ -43,7 +43,7 @@ static uint32_t guessGzipOutputSize(const void* data, uint32_t dataSize)
if (dataSize > 18) {
// Get ISIZE value from the end of file (little endian)
const uint8_t* tail = (const uint8_t*)data + dataSize - 4;
uint32_t uncompressedSize = tail[0] | (tail[1] << 8) | (tail[2] << 16) | (tail[3] << 24);
uint32_t uncompressedSize = (uint32_t) tail[0] | ((uint32_t) tail[1] << 8u) | ((uint32_t) tail[2] << 16u) | ((uint32_t) tail[3] << 24u);
// For valid gzip files, this value is the length of the uncompressed data modulo 2^32
if (uncompressedSize > 0) {