diff options
| author | JosJuice <josjuice@gmail.com> | 2019-03-30 16:20:45 +0100 |
|---|---|---|
| committer | JosJuice <josjuice@gmail.com> | 2019-04-09 14:18:46 +0200 |
| commit | a469fb315037d455884f25acb39bad57bc76e4ff (patch) | |
| tree | 739cd3a3c98859235c79cf59830515bcb6c5bb13 /Source/Core/DiscIO/CompressedBlob.cpp | |
| parent | eced9d7c7e2b05df304e800e4cfb7eae3ee9d2bd (diff) | |
VolumeVerifier: Check whether invalid blocks are unused
Diffstat (limited to 'Source/Core/DiscIO/CompressedBlob.cpp')
| -rw-r--r-- | Source/Core/DiscIO/CompressedBlob.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/Core/DiscIO/CompressedBlob.cpp b/Source/Core/DiscIO/CompressedBlob.cpp index 916773b90a..3dc9f86709 100644 --- a/Source/Core/DiscIO/CompressedBlob.cpp +++ b/Source/Core/DiscIO/CompressedBlob.cpp @@ -27,6 +27,7 @@ #include "DiscIO/Blob.h" #include "DiscIO/CompressedBlob.h" #include "DiscIO/DiscScrubber.h" +#include "DiscIO/Volume.h" namespace DiscIO { @@ -181,9 +182,11 @@ bool CompressFileToBlob(const std::string& infile_path, const std::string& outfi } DiscScrubber disc_scrubber; + std::unique_ptr<Volume> volume; if (sub_type == 1) { - if (!disc_scrubber.SetupScrub(infile_path, block_size)) + volume = CreateVolumeFromFilename(infile_path); + if (!volume || !disc_scrubber.SetupScrub(volume.get(), block_size)) { PanicAlertT("\"%s\" failed to be scrubbed. Probably the image is corrupt.", infile_path.c_str()); |
