From ef555ae606d879ba26a27153fc71fdda98317a56 Mon Sep 17 00:00:00 2001 From: eihrul Date: Tue, 1 Jun 2010 19:54:39 +0000 Subject: [PATCH] iqmbounds loading fix git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10224 d7cf8633-e32d-0410-b094-e92efae38249 --- model_alias.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/model_alias.c b/model_alias.c index 01a01fa4..df49c9e6 100644 --- a/model_alias.c +++ b/model_alias.c @@ -3129,6 +3129,7 @@ void Mod_INTERQUAKEMODEL_Load(dp_model_t *mod, void *buffer, void *bufferend) header->num_frames = LittleLong(header->num_frames); header->num_framechannels = LittleLong(header->num_framechannels); header->ofs_frames = LittleLong(header->ofs_frames); + header->ofs_bounds = LittleLong(header->ofs_bounds); header->num_comment = LittleLong(header->num_comment); header->ofs_comment = LittleLong(header->ofs_comment); header->num_extensions = LittleLong(header->num_extensions); @@ -3154,6 +3155,7 @@ void Mod_INTERQUAKEMODEL_Load(dp_model_t *mod, void *buffer, void *bufferend) pbase + header->ofs_poses + header->num_poses*sizeof(iqmpose_t) > pend || pbase + header->ofs_anims + header->num_anims*sizeof(iqmanim_t) > pend || pbase + header->ofs_frames + header->num_frames*header->num_framechannels*sizeof(unsigned short) > pend || + (header->ofs_bounds && pbase + header->ofs_bounds + header->num_frames*sizeof(iqmbounds_t) > pend) || pbase + header->ofs_comment + header->num_comment > pend) { Con_Printf("%s has invalid size or offset information\n", loadmodel->name); -- 2.39.2