From: MirceaKitsune Date: Mon, 30 Jan 2012 15:04:32 +0000 (+0200) Subject: Prevent using bad strings. Fixes crash X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=9a70a19e406eddcba5401c6d630b334d1edf3e79;p=voretournament%2Fvoretournament.git Prevent using bad strings. Fixes crash --- diff --git a/data/qcsrc/client/hud.qc b/data/qcsrc/client/hud.qc index 75ad88e2..787a80ff 100644 --- a/data/qcsrc/client/hud.qc +++ b/data/qcsrc/client/hud.qc @@ -1708,6 +1708,7 @@ void Sbar_Portrait() return; if(portrait_time + cvar("sbar_portrait_time") >= time) + if(portrait_image && portrait_name) // prevent using bad strings { drawpic(left - '120 80 0' - fade_pos, portrait_image, '120 160 0', '1 1 1', sbar_alpha_fg, DRAWFLAG_NORMAL); drawcolorcodedstring(left - '120 -80 0' - fade_pos, portrait_name, '12 12 0', sbar_alpha_fg, DRAWFLAG_NORMAL);