From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail2-relais-roc.national.inria.fr (mail2-relais-roc.national.inria.fr [192.134.164.83]) by yquem.inria.fr (Postfix) with ESMTP id CCAAFBC69 for ; Sat, 15 Sep 2007 16:24:21 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AgAAAFeI60bAXQImh2dsb2JhbACBV4w7AQEBCAon X-IronPort-AV: E=Sophos;i="4.20,258,1186351200"; d="scan'208";a="1235578" Received: from discorde.inria.fr ([192.93.2.38]) by mail2-smtp-roc.national.inria.fr with ESMTP; 15 Sep 2007 16:25:03 +0200 Received: from mail4-relais-sop.national.inria.fr (mail4-relais-sop.national.inria.fr [192.134.164.105]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l8FEOdbY016947 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=OK) for ; Sat, 15 Sep 2007 16:24:39 +0200 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ah4FAFeI60bVhW6V/2dsb2JhbACBVw X-IronPort-AV: E=Sophos;i="4.20,258,1186351200"; d="scan'208";a="16238255" Received: from server2.thinkcrime.de ([213.133.110.149]) by mail4-smtp-sop.national.inria.fr with ESMTP; 15 Sep 2007 16:25:02 +0200 Received: from hod-sarge-2005-10.lan.m-e-leypold.de (dslb-088-072-195-133.pools.arcor-ip.net [88.72.195.133]) (Authenticated sender: hod-sarge-2005-10@server2) by server2.thinkcrime.de (Postfix) with ESMTP id 261ED900245 for ; Sat, 15 Sep 2007 16:25:01 +0200 (CEST) Received: by hod-sarge-2005-10.lan.m-e-leypold.de (Postfix, from userid 1003) id 8217737962; Sat, 15 Sep 2007 16:29:42 +0200 (CEST) To: caml-list@inria.fr Subject: Re: [Caml-list] Closing all open file descriptors References: <006b01c7f699$275fd6d0$017ca8c0@countertenor> <200709141000.l8EA04x12648@virtutech.se> <1189806728.46eb0288d38b8@webmail.in-berlin.de> <1189847741.46eba2bd9d121@webmail.in-berlin.de> <20070915192631.2384ae5a.mle+ocaml@mega-nerd.com> <1189852990.46ebb73e7edc3@webmail.in-berlin.de> <200709151136.l8FBaH813458@virtutech.se> <1189858565.46ebcd05317b8@webmail.in-berlin.de> From: Markus E L Organization: N/A Date: Sat, 15 Sep 2007 16:29:42 +0200 In-Reply-To: <1189858565.46ebcd05317b8@webmail.in-berlin.de> (Oliver Bandel's message of "Sat, 15 Sep 2007 14:16:05 +0200") Message-ID: User-Agent: Some cool user agent (SCUG) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Miltered: at discorde with ID 46EBEB27.000 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; descriptors:01 markus:01 bandel:01 mattias:01 mattias:01 descriptors:01 gtk:01 gtk:01 markus:01 wrote:01 oliver:01 caml-list:01 handler:03 library:03 library:03 Oliver Bandel wrote: > Zitat von Mattias Engdeg=C3=A5 rd : > >> >If you have all your open descriptors in a list, >> >you can close them after a fork. >> >> That approach does not compose well --- descriptors opened by >> a library will be excluded. > [...] > > Oh, I have not seen this last sentence. > > Well, wouldn't the library offer possibilities > to close those files? > > Can you give an example on where you see problems? GTK and the X11 library without doubt open a plethora of file descriptors. If now you fork() in a gtk event handler -- can you tell me what happens to those file descriptors?=20 Regards -- Markus