() ri...@happyleptic.org
() Sat, 18 Sep 2010 08:29:28 +0200
Wait a minute, you can close a port ?
You can try; whether or not (and how) Guile obliges your request
is always a separate matter.
[...]
Thank you for the hint ! :)
Ashamedly yours,
No worries. I see your shame and raise
-[ Fri, Sep 17, 2010 at 11:03:13PM +0200, Thien-Thi Nguyen ]
> Perhaps you can make a port first; then use ???port->fdes???
> for file-descriptor based access; then close the port.
Wait a minute, you can close a port ?
... check check check ...
Ooookay. I might be blind somehow : Althoug I
() Cedric Cellier
() Fri, 17 Sep 2010 11:30:46 +0200
Any idea someone ?
Perhaps you can make a port first; then use ‘port->fdes’
for file-descriptor based access; then close the port.
IOW, start w/ the higher abstraction (port) and let gc DTRT.
Support I open a file, then make a port with the file description (with
scm_fdopen), then I close the file description. When the port will be
garbage collected the GC will attempt to close the port->fdes, ignoring
the EBADF error, so everything is OK.
Now supose I do this in a loop. The next open