diff --git a/src/protocol.cpp b/src/protocol.cpp index fe6e30ba..c64addfa 100755 --- a/src/protocol.cpp +++ b/src/protocol.cpp @@ -1473,7 +1473,7 @@ bool CProtocol::EvaluateCLRegisterServerMes ( const CHostAddress& InetAddr, // port number (2 bytes) RecServerInfo.iLocalPortNumber = - static_cast ( GetValFromStream ( vecData, iPos, 2 ) ); + static_cast ( GetValFromStream ( vecData, iPos, 2 ) ); // country (2 bytes) RecServerInfo.eCountry = @@ -1633,11 +1633,11 @@ bool CProtocol::EvaluateCLServerListMes ( const CHostAddress& InetAddr, // IP address (4 bytes) const quint32 iIpAddr = - static_cast ( GetValFromStream ( vecData, iPos, 4 ) ); + static_cast ( GetValFromStream ( vecData, iPos, 4 ) ); // port number (2 bytes) const quint16 iPort = - static_cast ( GetValFromStream ( vecData, iPos, 2 ) ); + static_cast ( GetValFromStream ( vecData, iPos, 2 ) ); // country (2 bytes) const QLocale::Country eCountry = diff --git a/src/testbench.h b/src/testbench.h index 9951e37e..9470ffce 100755 --- a/src/testbench.h +++ b/src/testbench.h @@ -90,10 +90,10 @@ protected: QHostAddress GenRandomIPv4Address() const { - uint32_t a = static_cast ( 192 ); - uint32_t b = static_cast ( 168 ); - uint32_t c = static_cast ( GenRandomIntInRange ( 1, 253 ) ); - uint32_t d = static_cast ( GenRandomIntInRange ( 1, 253 ) ); + quint32 a = static_cast ( 192 ); + quint32 b = static_cast ( 168 ); + quint32 c = static_cast ( GenRandomIntInRange ( 1, 253 ) ); + quint32 d = static_cast ( GenRandomIntInRange ( 1, 253 ) ); return QHostAddress( a << 24 | b << 16 | c << 8 | d ); }