NW> I have written a hot folder function making use of the
NW> wxDir::GetAllFiles to build a files list and then the::wxRenameFile
NW> function to move the files once detected. The issue is that if a large
NW> file is copied into the watch folder the wxDir::GetAllFiles function
NW> returns the file name prior to completion of the copy.
NW> The ::wxRenameFile then fails to correctly move the file, but does not
NW> return false.
I don't see why could this happen from reading the code. I do see that
wxRenameFile() ends up by calling wrename() in Unicode build and as we had
problems with wide char APIs under OS X in the past I wonder if wrename()
could misbehave there. Can you test if it works correctly on your system?
Regards,
VZ
--
TT-Solutions: wxWidgets consultancy and technical support
http://www.tt-solutions.com/
one idea might be to recheck the file-size after an arbitrary delay and if
the size hasn't changed, you could assume the copying/upload or whatever is
done
just my 0.02$
Best,
Stefan