I am trying to find filesize using -s operator. I looks like this:
my $filesz = -s $filename
I tried lots of various way but it can not get this size.
However, If I give static content instead of filename, it works fine
For exa:
$filesz = -s "/tmp/abc.txt"
This works fine.
I tried adding "
in filename, it didn't work. I removed \n
from filename using chomp, problem remains same. Anyone having any idea whats wrong here?