English version
Accueil     À propos     Téléchargement     Ressources     Contactez-nous    

Ce site est rarement mis à jour. Pour les informations les plus récentes, rendez-vous sur le nouveau site OCaml à l'adresse ocaml.org.

Browse thread
[Caml-list] closing file descriptors and channels
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2003-11-20 (17:14)
From: Nicolas George <nicolas.george@e...>
Subject: Re: [Caml-list] closing file descriptors and channels
Le decadi 30 brumaire, an CCXII, Xavier Leroy a écrit :
> The other possibility is to use close_out_noerr and close_in_noerr
> that will just ignore the errors arising from the closing of the
> underlying file descriptor.  But this can be dangerous:

This can be even more dangerous if another file has been opened between
the two closes (which can be invisible in threaded programs) and has got
the file descriptor that has just been closed.

I am preparing a RFC for this list about a complete rewrite of the I/O
subsystem, and this is definitively a problem that must be addressed.