2
0
mirror of https://github.com/FWGS/xash3d-fwgs synced 2024-11-22 09:56:22 +01:00

utils: mdldec: fix wrong conditions.

This commit is contained in:
Andrey Akhmichin 2023-12-28 22:18:41 +05:00 committed by Alibek Omarov
parent f705a7cd26
commit 520fc33394

View File

@ -385,7 +385,7 @@ static qboolean LoadMDL( const char *modelname )
}
}
if( filesize < sizeof( studiohdr_t ) || filesize != model_hdr->length )
if( filesize < sizeof( studiohdr_t ) || filesize != texture_hdr->length )
{
fprintf( stderr, "ERROR: Wrong file size! File %s may be corrupted!\n", texturename );
return false;
@ -427,7 +427,7 @@ static qboolean LoadMDL( const char *modelname )
return false;
}
if( filesize < sizeof( studiohdr_t ) || filesize != model_hdr->length )
if( filesize < sizeof( studiohdr_t ) || filesize != anim_hdr[i]->length )
{
fprintf( stderr, "ERROR: Wrong file size! File %s may be corrupted!\n", seqgroupname );
return false;