From: Martin Taibr Date: Thu, 17 Nov 2016 21:34:35 +0000 (+0100) Subject: fix unzoning X-Git-Tag: xonotic-v0.8.2~169^2~11 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=44524b8d8718b252c5e8507affc74d23beebd4e8;p=xonotic%2Fxonotic-data.pk3dir.git fix unzoning --- diff --git a/qcsrc/common/mutators/mutator/damagetext/damagetext.qc b/qcsrc/common/mutators/mutator/damagetext/damagetext.qc index cefdc9b03..900e42897 100644 --- a/qcsrc/common/mutators/mutator/damagetext/damagetext.qc +++ b/qcsrc/common/mutators/mutator/damagetext/damagetext.qc @@ -117,6 +117,7 @@ CLASS(DamageText, Object) ? sprintf("%d", total) : sprintf("%d (%d)", total, potential) ), s); + if (this.text) strunzone(this.text); this.text = strzone(s); } @@ -129,7 +130,7 @@ CLASS(DamageText, Object) } DESTRUCTOR(DamageText) { - strunzone(this.text); + if (this.text) strunzone(this.text); } ENDCLASS(DamageText) #endif