>...the use of ftruncate (2-BSD) to collapse the file to the appropriate >size after having written into it. Is there any POSIX/v7 idiom for this? No.