fixed test to test what happens when we close a file descriptor on which another thread is blocked reading
git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@13675 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02master
parent
1b54fa1d93
commit
9dda1aa675
|
@ -14,8 +14,7 @@ let main () =
|
||||||
let (rd, wr) = Unix.pipe() in
|
let (rd, wr) = Unix.pipe() in
|
||||||
let t = Thread.create
|
let t = Thread.create
|
||||||
(fun () ->
|
(fun () ->
|
||||||
ignore (Unix.write wr "0123456789" 0 10);
|
Thread.delay 1.0;
|
||||||
Thread.delay 3.0;
|
|
||||||
print_endline "closing fd...";
|
print_endline "closing fd...";
|
||||||
Unix.close rd;
|
Unix.close rd;
|
||||||
)
|
)
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
reading...
|
reading...
|
||||||
read returned
|
|
||||||
closing fd...
|
closing fd...
|
||||||
|
read returned
|
||||||
|
|
Loading…
Reference in New Issue