Correct detection of which ZIP files must be copied and which

ones must be recompressed.
This commit is contained in:
2017-05-11 02:49:14 +01:00
parent 42dee66551
commit 9f55ac4d2e
2 changed files with 8 additions and 1 deletions

View File

@@ -1,3 +1,9 @@
2017-05-11 Natalia Portillo <claunia@claunia.com>
* Workers.cs:
Correct detection of which ZIP files must be copied and
which ones must be recompressed.
2017-05-11 Natalia Portillo <claunia@claunia.com>
* Workers.cs:

View File

@@ -1107,13 +1107,14 @@ namespace osrepodbmgr.Core
if(format == "Zip")
{
Context.copyArchive = true;
ZipFile zf = ZipFile.Read(Context.path);
foreach(ZipEntry ze in zf)
{
// ZIP created with Mac OS X, need to be extracted with The UnArchiver to get correct ResourceFork structure
if(ze.FileName.StartsWith("__MACOSX", StringComparison.CurrentCulture))
{
Context.copyArchive = true;
Context.copyArchive = false;
break;
}
}