show sixup in status (#3512)

* show sixup in status

* format sixup in status

* str_copy
This commit is contained in:
nobody-mb 2021-01-15 12:26:40 -06:00 committed by GitHub
parent c0cbef731b
commit 46387373d1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -2732,8 +2732,17 @@ void CServer::ConStatus(IConsole::IResult *pResult, void *pUser)
str_format(aAuthStr, sizeof(aAuthStr), " key=%s %s", pThis->m_AuthManager.KeyIdent(pThis->m_aClients[i].m_AuthKey), pAuthStr); str_format(aAuthStr, sizeof(aAuthStr), " key=%s %s", pThis->m_AuthManager.KeyIdent(pThis->m_aClients[i].m_AuthKey), pAuthStr);
} }
str_format(aBuf, sizeof(aBuf), "id=%d addr=<{%s}> name='%s' client=%d secure=%s flags=%d%s%s", char aClientStr[128];
i, aAddrStr, pThis->m_aClients[i].m_aName, pThis->m_aClients[i].m_DDNetVersion, if(pThis->m_aClients[i].m_Sixup)
{
str_copy(aClientStr, "sixup", sizeof(aClientStr));
}
else
{
str_format(aClientStr, sizeof(aClientStr), "%d", pThis->m_aClients[i].m_DDNetVersion);
}
str_format(aBuf, sizeof(aBuf), "id=%d addr=<{%s}> name='%s' client=%s secure=%s flags=%d%s%s",
i, aAddrStr, pThis->m_aClients[i].m_aName, aClientStr,
pThis->m_NetServer.HasSecurityToken(i) ? "yes" : "no", pThis->m_aClients[i].m_Flags, aDnsblStr, aAuthStr); pThis->m_NetServer.HasSecurityToken(i) ? "yes" : "no", pThis->m_aClients[i].m_Flags, aDnsblStr, aAuthStr);
} }
else else