diff options
author | Harald Hoyer <harald@redhat.com> | 2013-02-14 12:26:13 +0100 |
---|---|---|
committer | Harald Hoyer <harald@redhat.com> | 2013-02-14 16:19:38 +0100 |
commit | a5c32cff1f56afe6f0c6c70d91a88a7a8238b2d7 (patch) | |
tree | b3cc19cede403ac324f56c54ca89db0feef2a72d /src/core/unit.c | |
parent | edc211f314f257921eb3599b5dca8d51984b9328 (diff) |
honor SELinux labels, when creating and writing config files
Also split out some fileio functions to fileio.c and provide a SELinux
aware pendant in fileio-label.c
see https://bugzilla.redhat.com/show_bug.cgi?id=881577
Diffstat (limited to 'src/core/unit.c')
-rw-r--r-- | src/core/unit.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/core/unit.c b/src/core/unit.c index f7d00b6030..86aaa1509a 100644 --- a/src/core/unit.c +++ b/src/core/unit.c @@ -46,6 +46,8 @@ #include "missing.h" #include "cgroup-attr.h" #include "mkdir.h" +#include "label.h" +#include "fileio-label.h" const UnitVTable * const unit_vtable[_UNIT_TYPE_MAX] = { [UNIT_SERVICE] = &service_vtable, @@ -2778,7 +2780,7 @@ int unit_write_drop_in(Unit *u, bool runtime, const char *name, const char *data return -ENOMEM; mkdir_p(p, 0755); - return write_one_line_file_atomic(q, data); + return write_one_line_file_atomic_label(q, data); } int unit_remove_drop_in(Unit *u, bool runtime, const char *name) { |