How do you determine if a file is empty in perl? You can use -s but it only counts the number of bytes. The file may have some bytes but for practical purposes it's still empty. Thanks in advance for any help offered.
when I iterate through my file I'm using a loop
<do {}unitl eof;> I suppose you could check for eof beforehand. Also I know the $. variable contains the number of lines that are written in the file you could check if that is 0?
Kris
kmcculler@portiva.com
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.