From: divverent Date: Tue, 11 May 2010 15:47:26 +0000 (+0000) Subject: properly strip the / from worldbasename X-Git-Tag: xonotic-v0.1.0preview~230^2~287 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=3ca7c53a5e44ff93c8c483581e89e4d3d17cbf80;p=xonotic%2Fdarkplaces.git properly strip the / from worldbasename git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10191 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/cl_parse.c b/cl_parse.c index 30ee1720..04819e73 100644 --- a/cl_parse.c +++ b/cl_parse.c @@ -452,7 +452,7 @@ static void CL_SetupWorldModel(void) { strlcpy(cl.worldname, cl.worldmodel->name, sizeof(cl.worldname)); FS_StripExtension(cl.worldname, cl.worldnamenoextension, sizeof(cl.worldnamenoextension)); - strlcpy(cl.worldbasename, !strncmp(cl.worldnamenoextension, "maps/", 5) ? cl.worldnamenoextension + 4 : cl.worldnamenoextension, sizeof(cl.worldbasename)); + strlcpy(cl.worldbasename, !strncmp(cl.worldnamenoextension, "maps/", 5) ? cl.worldnamenoextension + 5 : cl.worldnamenoextension, sizeof(cl.worldbasename)); Cvar_SetQuick(&cl_worldmessage, cl.worldmessage); Cvar_SetQuick(&cl_worldname, cl.worldname); Cvar_SetQuick(&cl_worldnamenoextension, cl.worldnamenoextension);