Skip to content

Commit 7a71aef

Browse files
dinosaurehhugo
authored andcommitted
fixe #24 Change O_APPEND to O_TRUNC for PID file
1 parent 56e2703 commit 7a71aef

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/server/ocsigen_server.ml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1401,7 +1401,7 @@ let start_server () = try
14011401
let f =
14021402
Unix.openfile
14031403
p
1404-
[Unix.O_WRONLY; Unix.O_CREAT; Unix.O_APPEND] 0o640 in
1404+
[Unix.O_WRONLY; Unix.O_CREAT; Unix.O_TRUNC] 0o640 in
14051405
ignore (Unix.write f spid 0 len);
14061406
Unix.close f
14071407
in

0 commit comments

Comments
 (0)