diff options
| author | LPFaint99 <lpfaint99@gmail.com> | 2009-07-01 06:48:02 +0000 |
|---|---|---|
| committer | LPFaint99 <lpfaint99@gmail.com> | 2009-07-01 06:48:02 +0000 |
| commit | 39b9b887c16f826866b0274f490ca646d86e5aa8 (patch) | |
| tree | b4918301e667aa921356f667488e09342f861845 /Source/Core/DiscIO/Src/DiscScrubber.cpp | |
| parent | 52e424485f1ce3e190e654bfad23ef74160b5535 (diff) | |
DiscScrubber: only close the file if it was successfully opened, fixes crash if you try to compress a wii game set to readonly
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3626 8ced0084-cf51-0410-be5f-012b33b47a6e
Diffstat (limited to 'Source/Core/DiscIO/Src/DiscScrubber.cpp')
| -rw-r--r-- | Source/Core/DiscIO/Src/DiscScrubber.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Source/Core/DiscIO/Src/DiscScrubber.cpp b/Source/Core/DiscIO/Src/DiscScrubber.cpp index 9b45a760e4..a4c29c7234 100644 --- a/Source/Core/DiscIO/Src/DiscScrubber.cpp +++ b/Source/Core/DiscIO/Src/DiscScrubber.cpp @@ -195,7 +195,7 @@ bool Scrub(const char* filename, CompressCB callback, void* arg) ERROR_LOG(DISCIO, "Really weird - failed to mark scrubbed disk as scrubbed :s"); cleanup: - fclose(pFile); + if (pFile) fclose(pFile); delete m_Sector1; delete m_FreeTable; |
