Revert "label: fix systemd-udev labeling of /run directory."
This reverts commit 9b5af248f0.
Udev now explicitely labels only files/directories in /dev. The selinux
array API is not released and will not work on other distros at this moment.
This commit is contained in:
+3
-3
@@ -52,7 +52,7 @@ void label_retest_selinux(void) {
|
||||
|
||||
#endif
|
||||
|
||||
int label_init(const char *prefixes[]) {
|
||||
int label_init(const char *prefix) {
|
||||
int r = 0;
|
||||
|
||||
#ifdef HAVE_SELINUX
|
||||
@@ -68,9 +68,9 @@ int label_init(const char *prefixes[]) {
|
||||
before_mallinfo = mallinfo();
|
||||
before_timestamp = now(CLOCK_MONOTONIC);
|
||||
|
||||
if (prefixes) {
|
||||
if (prefix) {
|
||||
struct selinux_opt options[] = {
|
||||
{ .type = SELABEL_OPT_SUBSET, .values = prefixes },
|
||||
{ .type = SELABEL_OPT_SUBSET, .value = prefix },
|
||||
};
|
||||
|
||||
label_hnd = selabel_open(SELABEL_CTX_FILE, options, ELEMENTSOF(options));
|
||||
|
||||
+1
-1
@@ -26,7 +26,7 @@
|
||||
#include <stdbool.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
int label_init(const char *prefixes[]);
|
||||
int label_init(const char *prefix);
|
||||
void label_finish(void);
|
||||
|
||||
int label_fix(const char *path, bool ignore_enoent);
|
||||
|
||||
Reference in New Issue
Block a user