From: z411 Date: Mon, 4 Apr 2022 20:00:25 +0000 (-0400) Subject: Use strcpy for centerprint title X-Git-Tag: xonotic-v0.8.5~94^2~3 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=db0adff0a2a3b9234974996f6ecc1685f23094d1;p=xonotic%2Fxonotic-data.pk3dir.git Use strcpy for centerprint title --- diff --git a/qcsrc/client/hud/panel/centerprint.qc b/qcsrc/client/hud/panel/centerprint.qc index 1cd22b493..307e3c899 100644 --- a/qcsrc/client/hud/panel/centerprint.qc +++ b/qcsrc/client/hud/panel/centerprint.qc @@ -159,10 +159,7 @@ void centerprint_ClearTitle() void centerprint_SetTitle(string title, float offset) { if(title != centerprint_title) { - if(centerprint_title) - strfree(centerprint_title); - - centerprint_title = strzone(CCR(title)); + strcpy(centerprint_title, CCR(title)); centerprint_title_offset = offset; } }