From 7f82ab821905abb341a8c4748495de13a781f070 Mon Sep 17 00:00:00 2001 From: malc Date: Tue, 31 Jan 2017 14:14:27 +0300 Subject: [PATCH] Fix selstring Close the write end of the pipe. --- main.ml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/main.ml b/main.ml index 674a444..c30fbf7 100644 --- a/main.ml +++ b/main.ml @@ -305,7 +305,8 @@ let selstring s = let bytes = Bytes.unsafe_of_string s in let n = tempfailureretry (Unix.write w bytes 0) l in if n != l - then impmsg "failed to write %d characters to sel pipe, wrote %d" l n + then impmsg "failed to write %d characters to sel pipe, wrote %d" l n; + clo "selstring pipe/w" w; with exn -> impmsg "failed to write to sel pipe: %s" @@ exntos exn end; clo "selstring pipe/r" r; -- 2.11.4.GIT