Add static cast to WriteVarInt

This commit is contained in:
DankParrot 2020-07-31 18:55:41 -07:00
parent c19b051bee
commit cb72973db2
1 changed files with 2 additions and 1 deletions

View File

@ -47,8 +47,9 @@ namespace Feather
} }
template <typename Int = int32_t> template <typename Int = int32_t>
inline void WriteVarInt(Int value) inline void WriteVarInt(Int val)
{ {
int32_t value = static_cast<int32_t>(val);
do { do {
uint8_t temp = uint8_t(value & 0b01111111); uint8_t temp = uint8_t(value & 0b01111111);
value >>= 7; value >>= 7;