http://www.perlmonks.org?node_id=728196


in reply to mark unreadable file so a loop does not read the file again

You have to be careful before changing the characteristics(binary, unreadable,..,) of a file. Because, it is going to affect you when you access the file for some other purpose.

It is better to log the read file names in a separate file(log) and check the existence of file name in the file(log) before reading the files.

  • Comment on Re: mark unreadable file so a loop does not read the file again