this looked dodgy

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2642 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2007-09-08 20:28:59 +00:00
parent 5a16c2f01d
commit 8935096360

View file

@ -3706,19 +3706,21 @@ void SV_ExtractFromUserinfo (client_t *cl)
char newname[80];
val = Info_ValueForKey (cl->userinfo, "team");
val[40] = 0; //trim to smallish length now (to allow for adding more.
Q_strncpyz (cl->team, val, sizeof(cl->teambuf));
// name for C code
val = Info_ValueForKey (cl->userinfo, "name");
val[40] = 0; //trim to smallish length now (to allow for adding more.
if (cl->protocol != SCP_BAD || *val)
{
SV_FixupName(val, newname);
if (strlen(newname) > 40)
newname[40] = 0;
}
else
newname[0] = 0;
if (!val[0] && cl->protocol != SCP_BAD)
if (!newname[0] && cl->protocol != SCP_BAD)
strcpy(newname, "Hidden");
else if (!stricmp(val, "console"))
{