---
src/journal/journalctl.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c
index 5f44fce..77a5fb1 100644
--- a/src/journal/journalctl.c
+++ b/src/journal/journalctl.c
@@ -748,6 +748,12 @@ static int setup_keys(void) {
return r < 0 ? -errno : -ENOTDIR;
}
+ r = access("/var/log/journal", R_OK | W_OK | X_OK);
+ if (r < 0) {
+ log_error("Insufficient permission on %s: %m",
"/var/log/journal");
+ return -errno;
+ }
+
r = sd_id128_get_machine(&machine);
if (r < 0) {
log_error("Failed to get machine ID: %s", strerror(-r));
--
1.8.3.2
_______________________________________________
systemd-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/systemd-devel