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=AWL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 5D203BC6C for ; Fri, 29 Jun 2007 12:18:06 +0200 (CEST) Received: from smtp112.sbc.mail.mud.yahoo.com (smtp112.sbc.mail.mud.yahoo.com [68.142.198.211]) by discorde.inria.fr (8.13.6/8.13.6) with SMTP id l5TAI4cL022573 for ; Fri, 29 Jun 2007 12:18:05 +0200 Received: (qmail 2173 invoked from network); 29 Jun 2007 10:18:04 -0000 Received: from unknown (HELO ?192.168.1.100?) (rftp@pacbell.net@69.230.222.200 with plain) by smtp112.sbc.mail.mud.yahoo.com with SMTP; 29 Jun 2007 10:18:03 -0000 X-YMail-OSG: ENfak2QVM1n_kKnLtwYX0bo60o5rOqS6y4urJsmsmhNXnDMsr93RyB1MbCT0cICssBw6xaei3NH14z46tN3P8S6mWOZgnxdTlcJn8g89gzeZrye0ldo- Message-ID: <4684DC4F.8030208@rftp.com> Date: Fri, 29 Jun 2007 03:17:51 -0700 From: Robert Roessler User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a6pre) Gecko/20070626 SeaMonkey/2.0a1pre MIME-Version: 1.0 To: Caml-list Subject: Re: [Caml-list] Waiting for float time References: <4682DCDF.5000301@crans.org> <4682E2D9.4050207@rftp.com> <891bd3390706280433u7b9c0ed6me56e8a6474c17310@mail.gmail.com> In-Reply-To: <891bd3390706280433u7b9c0ed6me56e8a6474c17310@mail.gmail.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Miltered: at discorde with ID 4684DC5C.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; yaron:01 minsky:01 ocaml:01 ocaml's:01 recognizes:01 transforming:01 crans:98 crans:98 idiom:01 wrote:01 wrote:01 unix:01 unix:01 exception:01 exception:01 Yaron Minsky wrote: > On 6/27/07, *Robert Roessler* > wrote: > > sayan@crans.org wrote: > > I believe the OCaml idiom for this is to use Unix.select with empty > lists for all THREE of the descriptor lists... and this does work on > Windows. > > > Note, on Unix at least, you need to wrap the call to select in an > exception handler, since select can be interrupted, at which point the > call throws an exception. Thanks for the reminder - I am too familiar with OCaml's Windows version of Unix.select, which recognizes and special-cases the "sleep-only" use of select by transforming it into a non-alertable [Win32] Sleep() call. ;) Robert Roessler roessler@rftp.com http://www.rftp.com