[FileTools, SimpleSort, ZipFile/Entry] TorrentZip works! Mostly!

Writing to torrentzip works but for some reason the compressed streams are not being generated at the correct size. This is odd and seems to only affect newly added files and not ones copied from other archives. Also, found some glaring flaws in the headered output that explains why I was having issues previously. Typos D=
This commit is contained in:
Matt Nadareski
2016-09-16 11:37:55 -07:00
parent 444fc1696b
commit c69dddbc26
4 changed files with 313 additions and 286 deletions

View File

@@ -337,6 +337,7 @@ namespace SabreTools.Helper
else
{
FileTools.WriteToArchive(input, _outdir, found);
//FileTools.WriteTorrentZip(input, _outdir, found, _logger);
}
}
}
@@ -404,12 +405,14 @@ namespace SabreTools.Helper
else
{
FileTools.WriteToArchive(newinput, _outdir, found);
//FileTools.WriteTorrentZip(newinput, _outdir, found, _logger);
}
}
// Then output the headered rom (renamed)
Rom newfound = found;
newfound.Name = Path.GetFileNameWithoutExtension(newfound.Name) + " (" + rom.HashData.CRC + ")" + Path.GetExtension(newfound.Name);
newfound.HashData = rom.HashData;
// Add rom to the matched list
key = newfound.HashData.Size + "-" + newfound.HashData.CRC;
@@ -450,6 +453,7 @@ namespace SabreTools.Helper
else
{
FileTools.WriteToArchive(input, _outdir, newfound);
//FileTools.WriteTorrentZip(input, _outdir, newfound, _logger);
}
}
}
@@ -535,7 +539,8 @@ namespace SabreTools.Helper
}
else
{
FileTools.WriteToArchive(outfile, _outdir, found);
FileTools.WriteToArchive(input, _outdir, found);
//FileTools.WriteTorrentZip(input, _outdir, found, _logger);
}
try