Mail Archives: djgpp/1998/03/12/22:33:43
At 04:25 3/12/1998 -0000, Neil wrote:
>I am used to writing C programs on UNIX. Now I need to write a noddy C
>program for DOS that outputs the amount of free disk space.
>
>I did write a version of "df" on UNIX, is there an equivalent of the statfs
>structure using DJGPP, or alternatively what's the easiest was of finding
>free disk space (apart from cutting up the output of system("dir c:\");...)
Yes, It's called `statfs'. :) I believe it's the same interface as Unix. See
its docs.
Incidentally, `df' comes with the ported GNU fileutils package, so you're
reinventing the wheel. Not that there's anything *wrong* with that... :)
Nate Eldredge
eldredge AT ap DOT net
- Raw text -