From e9ce6f6563d357749c8ae73c48ba7bc2efb68105 Mon Sep 17 00:00:00 2001 From: havoc Date: Tue, 21 Oct 2003 11:34:57 +0000 Subject: [PATCH] one more input underrun check in pvs decompression git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@3593 d7cf8633-e32d-0410-b094-e92efae38249 --- model_brush.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/model_brush.c b/model_brush.c index e927d009..1a66eae7 100644 --- a/model_brush.c +++ b/model_brush.c @@ -709,6 +709,11 @@ static void Mod_Q1BSP_DecompressVis(const qbyte *in, const qbyte *inend, qbyte * *out++ = c; else { + if (in == inend) + { + Con_DPrintf("Mod_Q1BSP_DecompressVis: input underrun on model \"%s\"\n", loadmodel->name); + return; + } for (c = *in++;c > 0;c--) { if (out == outend) -- 2.39.2