Version française
Home     About     Download     Resources     Contact us    
Browse thread
[Caml-list] Sys_error "Bad file descriptor"
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: wester@i...
Subject: [Caml-list] Sys_error "Bad file descriptor"
Hi,

I try to open a file with append mode. Opening and writing to the file 
works but when I try to flush or close the file I get an error message:

let h_out = open_out_gen ~mode:[Open_append; Open_creat] ~perm:666 "f1.txt";;
Printf.fprintf h_out "%s" "something";;
close_out h_out;;

Uncaught exception: Sys_error "Bad file descriptor".

I'm running OCaml 3.1 on Windows NT 4.0. Any help is appreciated.

Rolf Wester  
-------------------------------------
Rolf Wester
wester@ilt.fhg.de
-------------------
To unsubscribe, mail caml-list-request@inria.fr.  Archives: http://caml.inria.fr