소스 검색

[server] flush stdout before writing results to socket

Simon Krajewski 3 년 전
부모
커밋
6212d7c68d
1개의 변경된 파일1개의 추가작업 그리고 0개의 파일을 삭제
  1. 1 0
      src/compiler/server.ml

+ 1 - 0
src/compiler/server.ml

@@ -566,6 +566,7 @@ let mk_length_prefixed_communication allow_nonblock chin chout =
 	let write = Buffer.add_string bout in
 
 	let close = fun() ->
+		flush stdout;
 		IO.write_i32 chout (Buffer.length bout);
 		IO.nwrite_string chout (Buffer.contents bout);
 		IO.flush chout