[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Bauer, Christoph <Christoph.Bauer@l...> |
| Subject: | AW: [Caml-list] Unix.waitpid |
Sorry,
> let wait ?(delay_time = 0.01) pid idle x =
> let rec wait' () =
> idle x;
> delay delay_time;
> let pid = try fst (Unix.waitpid [Unix.WNOHANG] pid) with
> _ -> 1 in
> if pid <> 0 then wait' ()
> in wait' ()
this code is wrong, my original code was:
let rec wait' () =
idle x;
delay delay_time;
let wpid = try fst( Unix.waitpid [Unix.WNOHANG] pid) with _ -> pid in
if pid <> wpid then wait' ()
in wait' ()
Christoph Bauer