]> de.git.xonotic.org Git - xonotic/xonotic-data.pk3dir.git/blobdiff - qcsrc/menu/xonotic/screenshotimage.qc
Add strcpy to reduce explicit use of strzone/strunzone
[xonotic/xonotic-data.pk3dir.git] / qcsrc / menu / xonotic / screenshotimage.qc
index 8e8f3ccf738bd4f32de72be843b87510b558d8d8..af987e7b58c9ab78491ef7829a8e57a1885842f5 100644 (file)
@@ -19,9 +19,7 @@ void XonoticScreenshotImage_load(entity me, string theImage)
 {
        me.screenshotTime = time;
        me.src = theImage;
-       if (me.screenshotTitle)
-               strunzone(me.screenshotTitle);
-       me.screenshotTitle = strzone(substring(me.src, 13, strlen(theImage) - 13)); //strip "/screenshots/"
+       strcpy(me.screenshotTitle, substring(me.src, 13, strlen(theImage) - 13)); //strip "/screenshots/"
 
        me.initZoom(me); // this image may have a different size
        me.setZoom(me, 0, 0);