|
Home > Archive > Unix Programming > May 2007 > Api call for free disk space
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Api call for free disk space
|
|
| Adrian 2007-05-25, 1:19 pm |
| Anyone know if there is a posix/portablish api call for getting free
space from a disk?
TIA
Adrian
| |
| Eric Sosman 2007-05-25, 1:19 pm |
| Adrian wrote On 05/25/07 10:39,:
> Anyone know if there is a posix/portablish api call for getting free
> space from a disk?
What is "free" space on a disk?
If you want the free space in a file system, try
statvfs(). It's part of SUS and so should be widely
available, but the SUS warns that some returned data
may be meaingless on some platforms and file systems.
--
Eric.Sosman@sun.com
| |
| Adrian 2007-05-25, 1:19 pm |
| On May 25, 9:15 am, Eric Sosman <Eric.Sos...@sun.com> wrote:
> What is "free" space on a disk?
True :-) but you knew what I meant
> If you want the free space in a file system, try
> statvfs(). It's part of SUS and so should be widely
> available, but the SUS warns that some returned data
> may be meaingless on some platforms and file systems.
Perfect. Its on the flavors I need it on
|
|
|
|
|