diff --git a/src/store_bytes.h b/src/store_bytes.h index c34e43f..e1a11f3 100644 --- a/src/store_bytes.h +++ b/src/store_bytes.h @@ -37,7 +37,7 @@ inline size_t Store16(uint8_t* dst, size_t offset, int x) { *reinterpret_cast(dst + offset) = ((x & 0xFF) << 8) | ((x & 0xFF00) >> 8); #elif (defined(__BYTE_ORDER__) && (__BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)) - *reinterpret_cast(dst + offset) = reinterpret_cast(x); + *reinterpret_cast(dst + offset) = static_cast(x); #else dst[offset] = x >> 8; dst[offset + 1] = x; @@ -59,7 +59,7 @@ inline void Store16(int val, size_t* offset, uint8_t* dst) { *offset += 2; #elif (defined(__BYTE_ORDER__) && (__BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)) *reinterpret_cast(dst + *offset) = - reinterpret_cast(val); + static_cast(val); *offset += 2; #else dst[(*offset)++] = val >> 8;