summary refs log tree commit diff
path: root/chat.c
diff options
context:
space:
mode:
authorC. McEnroe2021-10-16 17:03:31 -0400
committerC. McEnroe2021-10-16 17:03:31 -0400
commitb6cf41ab77a4324b4f4cf0bc9e3d82a5fef9ebd4 (patch)
tree45fb76bbe6f5037d5827130c89e63e6d9cc22c16 /chat.c
parent54c632e8c35c3283a890c589f1b7937887c13877 (diff)
Import refactored xdg.c from pounce
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");
 	}