This commit is contained in:
Jack Andersen 2015-07-04 12:02:59 -10:00
commit 46bef74daa
3 changed files with 3 additions and 3 deletions

View File

@ -101,7 +101,7 @@ void DiscBase::IPartition::extractToDirectory(const SystemString& path, bool for
std::unique_ptr<IFileIO::IWriteStream> ws = NewFileIO(dolPath)->beginWriteStream();
ws->write(&hdr, sizeof(DOLHeader));
/* Calculate Dol size */
uint32_t dolSize = SBig(hdr.textOff[0]);
uint32_t dolSize = SBig(hdr.textOff[0]) - sizeof(DOLHeader);
for (uint32_t i = 0 ; i < 7 ; i++)
dolSize += SBig(hdr.textSizes[i]);
for (uint32_t i = 0 ; i < 11 ; i++)

View File

@ -18,7 +18,7 @@ public:
m_fstSz = SBig(vals[2]);
s->seek(0x2440 + 0x14);
s->read(vals, 8);
m_apploaderSz = SBig(vals[0]) + SBig(vals[1]);
m_apploaderSz = 32 + SBig(vals[0]) + SBig(vals[1]);
/* Yay files!! */
parseFST(*s.get());

View File

@ -236,7 +236,7 @@ public:
m_fstSz = SBig(vals[2]) << 2;
ds->seek(0x2440 + 0x14);
ds->read(vals, 8);
m_apploaderSz = SBig(vals[0]) + SBig(vals[1]);
m_apploaderSz = 32 + SBig(vals[0]) + SBig(vals[1]);
/* Yay files!! */
parseFST(*ds.get());