pcsx2: Throw the exception

Coverity CID 146842: Dereference after null check (FORWARD_NULL)
This commit is contained in:
Jonathan Li
2015-10-07 00:37:40 +01:00
parent 76e61d4ef1
commit addf3d5331
+1 -1
View File
@@ -150,7 +150,7 @@ void ElfObject::readFile()
FILE *f;
f = fopen( filename.ToUTF8(), "rb" );
if (f == NULL) Exception::FileNotFound( filename );
if (f == NULL) throw Exception::FileNotFound( filename );
fseek(f, 0, SEEK_SET);
rsize = fread(data.GetPtr(), 1, data.GetSizeInBytes(), f);