Re-added BSD string functions

This commit is contained in:
2023-05-01 08:10:00 +03:00
parent a04cd735de
commit 19cc2f3e34
61 changed files with 308 additions and 297 deletions

View File

@@ -172,7 +172,7 @@ void CLIENT_DESC::SetPhase(int iPhase)
TPacketGDSetup p;
memset(&p, 0, sizeof(p));
strncpy(p.szPublicIP, g_szPublicIP, sizeof(p.szPublicIP));
strlcpy(p.szPublicIP, g_szPublicIP, sizeof(p.szPublicIP));
if (!g_bAuthServer)
{
@@ -208,9 +208,9 @@ void CLIENT_DESC::SetPhase(int iPhase)
if (r.id != 0)
{
pck.dwID = r.id;
strncpy(pck.szLogin, r.login, sizeof(pck.szLogin));
strncpy(pck.szSocialID, r.social_id, sizeof(pck.szSocialID));
strncpy(pck.szHost, d->GetHostName(), sizeof(pck.szHost));
strlcpy(pck.szLogin, r.login, sizeof(pck.szLogin));
strlcpy(pck.szSocialID, r.social_id, sizeof(pck.szSocialID));
strlcpy(pck.szHost, d->GetHostName(), sizeof(pck.szHost));
pck.dwLoginKey = d->GetLoginKey();
buf.write(&pck, sizeof(TPacketLoginOnSetup));