summary refs log tree commit diff
path: root/chat.c
diff options
context:
space:
mode:
Diffstat (limited to 'chat.c')
-rw-r--r--chat.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/chat.c b/chat.c
index 54e7e5e..ba6c9a1 100644
--- a/chat.c
+++ b/chat.c
@@ -149,8 +149,8 @@ static void sandboxEarly(bool log) {
 	char *end = &promises[sizeof(promises)];
 
 	if (log) {
-		const char *logdir = dataMkdir("log");
-		int error = unveil(logdir, "wc");
+		char buf[PATH_MAX];
+		int error = unveil(dataPath(buf, sizeof(buf), "log", 0), "wc");
 		if (error) err(EX_OSERR, "unveil");
 		ptr = seprintf(ptr, end, " wpath cpath");
 	}