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

Closing Files

    Date: 23 February 1982  22:56-EST (Tuesday)
    From: FEINBERG at CMU-20C
	    Under twenex, why does Maclisp use restricted JFNs when you
    open a file? This is very annoying when it is important to close 
    a file, but you don't have a handle on it. . . .  Either the JFNs should 
    be unrestricted, or there should be a lisp functions which closes all 
    files, or you should at least be able to specify UNRESTRICTED as a file 
    mode to OPEN.
If a file-object is GC'd, then the GC will close it; but if you simply
forgot how to access it (e.g., you SETQ'd it to some variable whose name
you've forgotten, or put it in some list somewhere), then you can load
in the ARYFIL package and call (OPEN-FILES), which will return a list
of all currently-open file objects except (STATUS TTYIFA) and (STATUS TTYOFA) 
which aren't GC'able.    Source for this package contains some documentation 
of additional facilities;  it is on the CMU-20C machine as <MACLISP>ARYFIL.LSP.