You've already forked linux-packaging-mono
Imported Upstream version 4.4.2.4
Former-commit-id: 92904c9c5915c37244316e42ba99e7b934ed7ee2
This commit is contained in:
parent
589d484eee
commit
0b4a830db1
@ -82,10 +82,14 @@ namespace SharpCompress.Archive
|
||||
{
|
||||
key = key.Substring(1);
|
||||
}
|
||||
// .NET allows duplicate entries when saving and loading Zip files.
|
||||
// The following lines are disabled from upstream SharpCompress to allow this.
|
||||
#if ZIP_ALLOW_DUPLICATE_KEYS
|
||||
if (DoesKeyMatchExisting(key))
|
||||
{
|
||||
throw new ArchiveException("Cannot add entry with duplicate key: " + key);
|
||||
}
|
||||
#endif
|
||||
var entry = CreateEntry(key, source, size, modified, closeStream);
|
||||
newEntries.Add(entry);
|
||||
RebuildModifiedCollection();
|
||||
@ -101,7 +105,8 @@ namespace SharpCompress.Archive
|
||||
{
|
||||
p = p.Substring(1);
|
||||
}
|
||||
return string.Equals(p, key, StringComparison.OrdinalIgnoreCase);
|
||||
if (string.Equals(p, key, StringComparison.OrdinalIgnoreCase))
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
Reference in New Issue
Block a user