Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^2: Portable filesize check? (Win32)

by Eyck (Priest)
on Mar 10, 2005 at 09:50 UTC ( [id://438191]=note: print w/replies, xml ) Need Help??


in reply to Re: Portable filesize check? (Win32)
in thread Portable filesize check? (Win32)

As I said, the size reported by '-s' agrees with the one reported by dir.

But 'dir' is not omnipotent, and there are things like sparse, encrypted and compressed files, where there's no obvious size to report. Check ls command manual, it's got myriad of switches for a reason.

Problem was too much magic in perl file handling (or rather my lack of knowledge on that subject), and binmode fixed that.

Replies are listed 'Best First'.
Re^3: Portable filesize check? (Win32)
by thor (Priest) on Mar 10, 2005 at 12:36 UTC
    there are things like sparse, encrypted and compressed files, where there's no obvious size to report
    An operating system should not know anything about the contents of a file. What it should know is how many bytes on a disk that file occupies. So, the sparsity, encryptedness, or compressedness should not hinder the OS from knowing how many bytes that files takes up on disk.

    thor

    Feel the white light, the light within
    Be your own disciple, fan the sparks of will
    For all of us waiting, your kingdom will come

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://438191]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others goofing around in the Monastery: (5)
As of 2024-04-25 10:52 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found