diff options
| author | Lioncash <mathew1800@gmail.com> | 2015-08-19 04:53:04 -0400 |
|---|---|---|
| committer | Lioncash <mathew1800@gmail.com> | 2015-08-19 04:53:04 -0400 |
| commit | 2dd7702af0a360a8ee9eaacac637747fd9b121e5 (patch) | |
| tree | 84a63a5e89d07212a441341873767faad0839874 | |
| parent | d01356d312a05e9866feed20bfa653206318fb7b (diff) | |
| parent | 20081a98f69c7390b11b7731ce9908502fc1717d (diff) | |
Merge pull request #2830 from JosJuice/disc-scrubber-nullptr
DiscScrubber: Add another nullptr check
| -rw-r--r-- | Source/Core/DiscIO/DiscScrubber.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Source/Core/DiscIO/DiscScrubber.cpp b/Source/Core/DiscIO/DiscScrubber.cpp index 8f2eb8ee5b..e1b46450c4 100644 --- a/Source/Core/DiscIO/DiscScrubber.cpp +++ b/Source/Core/DiscIO/DiscScrubber.cpp @@ -95,6 +95,9 @@ bool SetupScrub(const std::string& filename, int block_size) m_BlocksPerCluster = CLUSTER_SIZE / m_BlockSize; m_Disc = CreateVolumeFromFilename(filename); + if (!m_Disc) + return false; + m_FileSize = m_Disc->GetSize(); u32 numClusters = (u32)(m_FileSize / CLUSTER_SIZE); |
