[Nickle] files not auto-closed on exit?
Keith Packard
nickle@nickle.org
Tue, 22 Apr 2003 15:47:40 -0700
Around 14 o'clock on Apr 22, Bart Massey wrote:
> I suppose that the data is stuck in the Nickle heap on exit, having not
> been flushed into stdio from whence it would be flushed to the OS before
> normal program termination.
Nickle can't use stdio as it doesn't have reliable indications of partial
reads and writes, and breaks horribly on most systems when file
descriptors are in non-blocking mode.
> The question is whether Nickle needs to keep a list of all the open files
> and install an exit handler...
It looks like Nickle needs some help with file management; it doesn't even
flush files that are dropped when garbage collecting.
Suggestions for dealing with stalled output and other vageries are welcome.
-keith