From abb4e9e2fa68c38f71fedc6d1ce2e78fcaa59495 Mon Sep 17 00:00:00 2001 From: nicm Date: Sat, 31 Oct 2015 13:12:03 +0000 Subject: The output log is only useful once and it means creating a file, so open it once at startup instead of in every call to tty_open. --- server.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'server.c') diff --git a/server.c b/server.c index 2af2c442..bc3fa51d 100644 --- a/server.c +++ b/server.c @@ -173,6 +173,8 @@ server_start(struct event_base *base, int lockfd, char *lockfile) } close(pair[0]); + if (debug_level > 3) + tty_create_log(); if (pledge("stdio rpath wpath cpath fattr unix recvfd proc exec tty " "ps", NULL) != 0) fatal("pledge failed"); -- cgit v1.2.3