mirror of
https://github.com/systemd/systemd.git
synced 2025-03-19 22:50:17 +03:00
Merge 31cb323b5019e1182d5c27e3f8c0cbca1a1d1579 into fdab24bf6acc62d3011f9b5abdf834b4886642b2
This commit is contained in:
commit
2868ee5134
@ -1031,6 +1031,15 @@ static int setup_credentials_internal(
|
||||
return r;
|
||||
}
|
||||
|
||||
if (workspace_mounted && !final_mounted && dir_is_empty(where, /* ignore_hidden_or_backup = */ false) > 0) {
|
||||
/* We actually did not produce any credentials in a new mount. Thus, we fall back
|
||||
* to the plain (empty) directory rather than leaving an empty mount behind. */
|
||||
r = umount_verbose(LOG_DEBUG, workspace, MNT_DETACH|UMOUNT_NOFOLLOW);
|
||||
if (r < 0)
|
||||
return r;
|
||||
workspace_mounted = false;
|
||||
}
|
||||
|
||||
if (workspace_mounted) {
|
||||
if (!final_mounted) {
|
||||
/* Make workspace read-only now, so that any bind mount we make from it defaults to
|
||||
|
Loading…
x
Reference in New Issue
Block a user