X-Git-Url: http://de.git.xonotic.org/?a=blobdiff_plain;f=host.c;h=c7f92fa24b914f0efe17bbf26f7ff718ce6d5b45;hb=ac947d2fbb445473c266390a1fca26c8be8611c4;hp=e6b2084093a8cf4219975f02e13afe788b9bec05;hpb=5bdc0879026939f551a3ff217064732d59731be2;p=xonotic%2Fdarkplaces.git diff --git a/host.c b/host.c index e6b20840..c7f92fa2 100644 --- a/host.c +++ b/host.c @@ -112,7 +112,7 @@ void Host_Error (const char *error, ...) va_list argptr; va_start (argptr,error); - vsprintf (hosterrorstring1,error,argptr); + vsnprintf (hosterrorstring1,sizeof(hosterrorstring1),error,argptr); va_end (argptr); Con_Printf("Host_Error: %s\n", hosterrorstring1); @@ -386,7 +386,7 @@ void Host_ClientCommands(const char *fmt, ...) char string[1024]; va_start(argptr,fmt); - vsprintf(string, fmt,argptr); + vsnprintf(string, sizeof(string), fmt, argptr); va_end(argptr); MSG_WriteByte(&host_client->message, svc_stufftext); @@ -563,7 +563,7 @@ qboolean Host_FilterTime (double time) double timecap, timeleft; realtime += time; - if (sys_ticrate.value < 0.01 || sys_ticrate.value > 0.1) + if (sys_ticrate.value < 0.01 || sys_ticrate.value > 0.10001) Cvar_SetValue("sys_ticrate", bound(0.01, sys_ticrate.value, 0.1)); if (slowmo.value < 0) Cvar_SetValue("slowmo", 0); @@ -1009,11 +1009,16 @@ void Host_Shutdown(void) // AK shutdown PRVM // AK hmm, no PRVM_Shutdown(); yet + CL_Video_Shutdown(); Host_SaveConfig_f(); CDAudio_Shutdown (); + S_Terminate (); NetConn_Shutdown (); + PR_Shutdown (); + COM_Shutdown (); + Cbuf_Shutdown (); if (cls.state != ca_dedicated) { @@ -1021,7 +1026,10 @@ void Host_Shutdown(void) VID_Shutdown(); } + Cmd_Shutdown(); + CL_Shutdown(); Sys_Shutdown(); Log_Close (); + Memory_Shutdown(); }