Hello.
I have a fascinating issue where I zip up a whole directory but intermittently a single file does not make it into the zip archive - even though it seems identical in perms to all the rest, and even though I can “see” the call to ZipFile::Builder::addFile going off!
I realized that in fact that file is being written just before I create the archive, and in the very same thread - so there can’t be more than a few microseconds between its creation and when it’s added to the archive. The file is successfully seen by my DirectoryIterator, ZipFile::Builder::addFile is successfully called on it, and yet that file, only, is not included in the .zip archive - it’s as if whatever builds the zip file hasn’t “caught up” with the actual state of the disk yet…!
If I, for example, write the file, sleep the thread for 100ms, and then create the archive, it works perfectly well every time.
I’m actually perfectly satisfied with that solution, because it’s an operation that’s only called once, and that rarely. However, this seems like a potential issue, and I thought I should report it.
My system stats:
juce_version: "JUCE v2.0.18"
operating_system_type: 4096
operating_system_name: "Mac OSX 10.6"
is_operating_system_64_bit: true
osx_minor_version_number: 6
logon_name: "tom"
full_user_name: "Tom Ritchford"
computer_name: "hofmann"
num_cpus: 8
cpu_speed_in_megahertz: 2800
cpu_vendor: "GenuineIntel"
has_mmx: true
has_sse: true
has_sse2: true
has_3dnow: false
memory_size_in_megabytes: 14336
which amusingly enough happen to be the contents of the file that refuses to save!