@c truncate a file to a given length
It return 0 on success and -1 on error.
int file_truncate(FILE *fp, long lNewFileSize ){