From: terencehill Date: Thu, 26 Nov 2015 13:34:04 +0000 (+0100) Subject: Another variable for the zoned string isn't needed in this case X-Git-Tag: xonotic-v0.8.2~1467^2~10 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=47657995a5256348fd223891d6f58f3366a59f09;p=xonotic%2Fxonotic-data.pk3dir.git Another variable for the zoned string isn't needed in this case --- diff --git a/qcsrc/menu/xonotic/hudskinlist.qc b/qcsrc/menu/xonotic/hudskinlist.qc index aa339fea9..49a3ecaa3 100644 --- a/qcsrc/menu/xonotic/hudskinlist.qc +++ b/qcsrc/menu/xonotic/hudskinlist.qc @@ -76,7 +76,7 @@ void getAllHUDSkins(entity me, string subdir) s = "*"; s = strcat(subdir, "hud_", s, ".cfg"); float strlen_subdir = strlen(subdir); - string zoned_subdir = strzone(subdir); + subdir = strzone(subdir); float list, i, n; list = search_begin(s, false, true); @@ -86,15 +86,15 @@ void getAllHUDSkins(entity me, string subdir) int bufsize = buf_getsize(me.listHUDSkin); for(i = 0; i < n; ++i) { - bufstr_set(me.listHUDSkin, bufsize + i * HUDSKINPARM_COUNT + HUDSKINPARM_PATH, zoned_subdir); + bufstr_set(me.listHUDSkin, bufsize + i * HUDSKINPARM_COUNT + HUDSKINPARM_PATH, subdir); s = search_getfilename(list, i); // get initial full file name s = substring(s, strlen_subdir + 4, (strlen(s) - strlen_subdir - 4 - 4)); // remove "hud_" prefix and ".cfg" suffix bufstr_set(me.listHUDSkin, bufsize + i * HUDSKINPARM_COUNT + HUDSKINPARM_NAME, s); } search_end(list); } - if(zoned_subdir) - strunzone(zoned_subdir); + if(subdir) + strunzone(subdir); } void XonoticHUDSkinList_getHUDSkins(entity me)