From 248fb833f9883b714c48cd3edac2b212cbcd565f Mon Sep 17 00:00:00 2001 From: Omar Polo Date: Sun, 3 Mar 2024 15:43:58 +0000 Subject: [PATCH] fix `log access path' with chroot We should open the log file inside the chroot; missed in 4acf495f41d2c26136e99072293ca8b9bff91dc0. See https://github.com/omar-polo/gmid/issues/24 --- gmid.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gmid.c b/gmid.c index f264670..bf1aedc 100644 --- a/gmid.c +++ b/gmid.c @@ -412,7 +412,7 @@ main_send_logfd(struct conf *conf) goto done; } - fd = open(conf->log_access, O_WRONLY|O_CREAT|O_APPEND, 0600); + fd = open(path, O_WRONLY|O_CREAT|O_APPEND, 0600); if (fd == -1) log_warn("can't open %s", conf->log_access); }