ftruncate does not work with rw file handles

Florian Weimer fweimer@redhat.com
Tue Dec 12 20:25:00 GMT 2017


On 12/12/2017 09:08 PM, Marc Pawlowsky wrote:
> Is it intentional that ftruncate does not work with read/write file
> handles, or am I doing somthing wrong?

>    test("rw");

"rw" opens a read-only file, the read-write mode is "r+" or "w+".

Florian



More information about the Libc-help mailing list