mirror of
https://github.com/Detanup01/gbe_fork.git
synced 2024-11-27 05:04:01 +08:00
update this snprintf from latest sdk
This commit is contained in:
parent
596706fea9
commit
ae212c5d3e
@ -150,9 +150,9 @@ inline const char *servernetadr_t::ToString( uint32 unIP, uint16 usPort ) const
|
|||||||
static int nBuf = 0;
|
static int nBuf = 0;
|
||||||
unsigned char *ipByte = (unsigned char *)&unIP;
|
unsigned char *ipByte = (unsigned char *)&unIP;
|
||||||
#ifdef VALVE_BIG_ENDIAN
|
#ifdef VALVE_BIG_ENDIAN
|
||||||
_snprintf (s[nBuf], sizeof( s[nBuf] ), "%u.%u.%u.%u:%i", (int)(ipByte[0]), (int)(ipByte[1]), (int)(ipByte[2]), (int)(ipByte[3]), usPort );
|
snprintf(s[nBuf], sizeof( s[nBuf] ), "%u.%u.%u.%u:%i", (int)(ipByte[0]), (int)(ipByte[1]), (int)(ipByte[2]), (int)(ipByte[3]), usPort );
|
||||||
#else
|
#else
|
||||||
_snprintf (s[nBuf], sizeof( s[nBuf] ), "%u.%u.%u.%u:%i", (int)(ipByte[3]), (int)(ipByte[2]), (int)(ipByte[1]), (int)(ipByte[0]), usPort );
|
snprintf(s[nBuf], sizeof( s[nBuf] ), "%u.%u.%u.%u:%i", (int)(ipByte[3]), (int)(ipByte[2]), (int)(ipByte[1]), (int)(ipByte[0]), usPort );
|
||||||
#endif
|
#endif
|
||||||
const char *pchRet = s[nBuf];
|
const char *pchRet = s[nBuf];
|
||||||
++nBuf;
|
++nBuf;
|
||||||
|
Loading…
Reference in New Issue
Block a user