mirror of
https://github.com/microsoft/DirectXTex.git
synced 2026-02-05 20:56:13 +01:00
Fixed file length validation problem in LoadDDSFromFile
This commit is contained in:
@@ -1573,7 +1573,7 @@ HRESULT LoadFromDDSFile( LPCWSTR szFile, DWORD flags, TexMetadata* metadata, Scr
|
||||
}
|
||||
else
|
||||
{
|
||||
if ( remaining > image.GetPixelsSize() )
|
||||
if ( remaining < image.GetPixelsSize() )
|
||||
{
|
||||
image.Release();
|
||||
return E_FAIL;
|
||||
|
||||
Reference in New Issue
Block a user