[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lynx-dev Re: [-dev.12] experimental text entry fields patch (updated

From: Bela Lubkin
Subject: Re: lynx-dev Re: [-dev.12] experimental text entry fields patch (updated)
Date: Sun, 10 Jan 1999 16:46:26 -0800

Kim DeVaughn wrote:

> On Sun, Jan 10, 1999, Serge MUNHOVEN (address@hidden) said:
> |
> | What about creating a subdirectory (e.g. with a name derived from the PID)
> | in TMP_SPACE and chdir to it right at the startup of lynx. You would only
> | have to remove it all at once when shutting down ?  This would apply to all
> | temporary files created, not only edited textareas. I used to do this in
> | shell wrappers around programs.
> Well lynx's temp files already use the pid in their filenames, and you
> can't just do (an equivalent of) "rm -f some-dir" and have it and all
> its contents blown away ... you still need to unlink() the individual
> files in it before rmdir()'ing the directory.

But this is easily done by searching the directory (same methodology as
in HTLoadFile(), in fact).

> Lynx already unlink()'s all its temp files at shutdown time (since it
> keeps track of those that it's created), however since it doesn't "know
> about" backup files that (may have been) spun-off by an editor, it would
> have to either 1) leave them laying around, or 2) walk thru some dir
> looking for filenames of the form Lpid-nTMP.ext, or 3) be told about
> there being (possible) backups, via an "extension variable", which it
> could then stat/unlink along with the "real" temp file (or at some other
> time when the filename is available).

If Lynx cd's to a purpose-created directory before running an external
editor, it doesn't have to think about extensions at all.  *All* files
in that directory are garbage; just read the directory, delete all
files, then the directory itself.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]