The stupid question is the question not asked | |
PerlMonks |
Re^3: File::Copy - move() function corrupting filesby afoken (Chancellor) |
on Aug 26, 2014 at 20:22 UTC ( [id://1098666]=note: print w/replies, xml ) | Need Help?? |
Don't scan for files yourself, make the operating system notify you of changes in the filesystem (inotify or similar APIs). Make sure your code starts processing only after a new file (opened for writing) is closed. For inotify, this seems to be indicated by the IN_CLOSE_WRITE event. Alexander
-- Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
In Section
Seekers of Perl Wisdom
|
|