Fixed hexen2 hub support.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@4477 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2013-09-18 21:43:06 +00:00
parent 4cd41b9e49
commit 4e8073aedd

View file

@ -326,7 +326,7 @@ void SV_SaveSpawnparms (qboolean dontsave)
if (PR_FindGlobal(svprogfuncs, "ClientReEnter", 0, NULL)) if (PR_FindGlobal(svprogfuncs, "ClientReEnter", 0, NULL))
{//oooh, evil. {//oooh, evil.
char buffer[65536*4]; char buffer[65536*4];
int bufsize = sizeof(buffer); int bufsize = 0;
char *buf; char *buf;
for (j=0 ; j<NUM_SPAWN_PARMS ; j++) for (j=0 ; j<NUM_SPAWN_PARMS ; j++)
host_client->spawn_parms[j] = 0; host_client->spawn_parms[j] = 0;
@ -336,7 +336,7 @@ void SV_SaveSpawnparms (qboolean dontsave)
if (host_client->spawninfo) if (host_client->spawninfo)
Z_Free(host_client->spawninfo); Z_Free(host_client->spawninfo);
host_client->spawninfo = Z_Malloc(bufsize+1); host_client->spawninfo = Z_Malloc(bufsize+1);
memcpy(host_client->spawninfo, buf, bufsize); memcpy(host_client->spawninfo, buf, bufsize+1);
host_client->spawninfotime = sv.time; host_client->spawninfotime = sv.time;
} }