1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-01 17:51:22 +03:00

machined: make image read-only check indepenednt on own privs

This commit is contained in:
Lennart Poettering 2014-12-26 19:36:25 +01:00
parent 8937e7b689
commit 08ff5529df

View File

@ -112,7 +112,7 @@ static int image_make(
read_only = read_only =
(path && path_startswith(path, "/usr")) || (path && path_startswith(path, "/usr")) ||
faccessat(dfd, filename, W_OK, AT_EACCESS) < 0; (faccessat(dfd, filename, W_OK, AT_EACCESS) < 0 && errno == EROFS);
if (S_ISDIR(st.st_mode)) { if (S_ISDIR(st.st_mode)) {