pcsx2/cdvd: kill a small memory leak

This commit is contained in:
Gregory Hainaut 2014-07-20 22:54:58 +02:00
parent e7d0a0345e
commit 1d5b250b58
1 changed files with 4 additions and 1 deletions

View File

@ -243,7 +243,10 @@ bool InputIsoFile::Open( const wxString& srcfile, bool testOnly )
m_reader->SetBlockSize(m_blocksize);
// Returns the original reader if single-part or a Multipart reader otherwise
AsyncFileReader* m_reader_old = m_reader;
m_reader = MultipartFileReader::DetectMultipart(m_reader);
if (m_reader != m_reader_old) // Not the same object the old one need to be deleted
delete m_reader_old;
}
m_blocks = m_reader->GetBlockCount();