X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=blobdiff_plain;f=src%2Fcore%2Fmachine-id-setup.c;h=f154800484f823fe1628b7a27826b3ab937ffb5c;hp=e2e6d0226995f88b1714a32c4132629bced42dd8;hb=3577de7ac39c54821e1d1d946db65e109dfb94b2;hpb=96e264415033ef9b07c062850aed4cac316f20b8 diff --git a/src/core/machine-id-setup.c b/src/core/machine-id-setup.c index e2e6d0226..f15480048 100644 --- a/src/core/machine-id-setup.c +++ b/src/core/machine-id-setup.c @@ -181,6 +181,7 @@ int machine_id_setup(const char *root) { * will be owned by root it doesn't matter much, but maybe * people look. */ + mkdir_parents(etc_machine_id, 0755); fd = open(etc_machine_id, O_RDWR|O_CREAT|O_CLOEXEC|O_NOCTTY, 0444); if (fd >= 0) writable = true;