Re: [nottingham] Hassle with perl script

From: Matthew Walton (mxw00u@cs.nott.ac.uk)
Date: Tue 08 Jan 2002 - 12:40:27 GMT


On Tue, 2002-01-08 at 12:03, Robert Davies wrote:

> I think it's a good suggestion, and it's not just good practice, because
> FILES is not getting flushed, before it's re-opened as FILES2.
>
> Even better would be to open it once, for reading and writing, and write
> first, and then through the same file descriptor read it back. This method
> allows you to delete the written file immediately after opening it.
>
> I forget how easy that is to do in perl(1), you might have to go to lower
> level file I/O or one of the modules to do it.

But actually, if it's just a temporary file being output, can't it just
write to a list in memory instead of writing to disk? That's assuming
there's enough memory, of course...
--------------------------------------------------------------------
http://www.lug.org.uk http://www.linuxportal.co.uk
http://www.linuxjob.co.uk http://www.linuxshop.co.uk
--------------------------------------------------------------------



This archive was generated by hypermail 2.1.3 : Tue 08 Jan 2002 - 12:48:09 GMT