summaryrefslogtreecommitdiff
path: root/src/udev
diff options
context:
space:
mode:
authorWaLyong Cho <walyong.cho@samsung.com>2015-07-28 02:43:55 +0900
committerWaLyong Cho <walyong.cho@samsung.com>2015-08-04 21:11:19 +0900
commit5ab58c2091636209231fc3fd5bf97f21b77deb88 (patch)
tree143512aa8d5602a718167e577278982bedc2e215 /src/udev
parent7b9c9ab810eb8746cece22de1dfec375caf4cd13 (diff)
smack-util: revise smack-util apis and add read smack attr apis
- Add smack xattr lookup table - Unify all of mac_smack_apply_xxx{_fd}() to mac_smack_apply() and mac_smack_apply_fd(). - Add smack xattr read apis similar with apply apis as mac_smack_read{_fd}().
Diffstat (limited to 'src/udev')
-rw-r--r--src/udev/udev-node.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/udev/udev-node.c b/src/udev/udev-node.c
index d824172b89..e730fb45f1 100644
--- a/src/udev/udev-node.c
+++ b/src/udev/udev-node.c
@@ -309,7 +309,7 @@ static int node_permissions_apply(struct udev_device *dev, bool apply,
} else if (streq(name, "smack")) {
smack = true;
- r = mac_smack_apply(devnode, label);
+ r = mac_smack_apply(devnode, SMACK_ATTR_ACCESS, label);
if (r < 0)
log_error_errno(r, "SECLABEL: failed to set SMACK label '%s': %m", label);
else
@@ -323,7 +323,7 @@ static int node_permissions_apply(struct udev_device *dev, bool apply,
if (!selinux)
mac_selinux_fix(devnode, true, false);
if (!smack)
- mac_smack_apply(devnode, NULL);
+ mac_smack_apply(devnode, SMACK_ATTR_ACCESS, NULL);
}
/* always update timestamp when we re-use the node, like on media change events */