Mail Archives: djgpp/2000/07/02/15:21:50
> From: April <awhite AT user DOT rose DOT com>
> Newsgroups: comp.os.msdos.djgpp
> Date: Sat, 01 Jul 2000 19:32:25 -0500
>
> Using djgpp 2.9.5.2, I want to use the ftruncate() function to increase
> the size of my file; according to the documentation, it is to return
> non-zero on failure.
>
> I am testing with my ram-drive, and when all available space is
> allocated, zero is still returned.
>
> I have also tested on my hard-drive (enlarging the file to a reasonable
> size then an unreasonable size).
> Both returned zero.
>
> Is this a bug? Feature?
Please post a short test program that could be compiled and used to
investigate this. It's possible that this is a feature (or
misfeature) of DOS, since `ftruncate' simply calls a couple of DOS
functions.
Btw, in general, `ftruncate' is for truncating files, not extending
them.
- Raw text -