Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
Re: [Caml-list] Pipes in 3.01
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Laszlo Nemeth <laszlo@r...>
Subject: Re: [Caml-list] Pipes in 3.01
Thanks for all those (Damien, Francois, Fabrice) who replied and
pointed out my misunderstanding of IPC. Nevertheless, I did not manage
to make it work with 'create_process'. Instead, I started using
'open_process' which works wonderfully.

Thanks again. Laszlo

--- the working snippet:
module DaVinciAPI : DAVINCIAPI =
    exception DaVinciInitError
    let daVinci () =
      begin try
        let (dIn, dOut) = Unix.open_process "daVinci -pipe" 
        and buf = String.create 10 in
        let len = (Unix.descr_of_in_channel dIn) ~buf ~pos:0 10
      with Unix.Unix_error _ -> raise DaVinciInitError

To unsubscribe, mail  Archives: