This project is read-only.


Setting Entry._Source to "None" after Save Causes Exceptions in Later Operations


Saving a zip file twice can cause an exception.
public void DummyTest()
  var zip = Provider.NodeRepository.ZipFile;
  var entries = zip.Entries.Where(e => e.FileName.Contains("Download")).ToArray();
  //PART1 - Add directory and save

  //PART2 - Rename paths (not related to XX directory from above) and save
  foreach (var zipEntry in entries)
    zipEntry.FileName = zipEntry.FileName.Replace("Download", "Download2");
It seems to reset the Source property of saved entries to "None" which causes exceptions when saving more than once.
A description of the issue can be found here:
As a quick guess, it might be that after saving, the Source should be "ZipFile" rather than "None", but I don't know about the implications though.
Closed Jun 18, 2011 at 2:06 PM by Cheeso
fixed in changeset 79377. First binary with this fix: V1.9.1.6


Cheeso wrote Jun 18, 2011 at 6:31 AM

I've put your code into the test suite; now testing. I don't recall now why I set the _Source to None, rather than ZipFile. I'll have a close look and see ... it could just be a simple mistake ("Typo") in the code.

wrote Jun 18, 2011 at 2:06 PM

wrote Feb 22, 2013 at 2:43 AM

wrote May 16, 2013 at 1:31 PM