in reply to Re: How do I pre-extend a file to a specified size
in thread How do I pre-extend a file to a specified size
The resulting file on Win98 is one byte long!! On VMS it is one block (minimum file size). It would appear that the seek doesn't extend the file past its current size (initially 0 bytes). Any suggestion appreciated.open HANDLE, ">temp.tmp" || die; $desired_size=1000000; seek HANDLE, 0, $desired_size -1; print HANDLE "\0"; seek HANDLE, 0, 0; close HANDLE;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Answer: How do I pre-extend a file to a specified size
by chipmunk (Parson) on Jan 05, 2001 at 07:11 UTC | |
by DMisener (Initiate) on Jan 05, 2001 at 18:02 UTC | |
by tye (Sage) on Jan 05, 2001 at 22:42 UTC |