aboutsummaryrefslogtreecommitdiffstats
path: root/libselinux
diff options
context:
space:
mode:
authorNick Kralevich <nnk@google.com>2019-02-21 12:56:14 -0800
committerNick Kralevich <nnk@google.com>2019-02-21 12:56:14 -0800
commit28cf7ea80d067f070453d47a9a1881517f14d433 (patch)
treea69077225ab87d346497741aa8f21ffd2e6f6d92 /libselinux
parent13030b2fd3cc59d77d953455827b9f64da66e0da (diff)
parent6b89b1f9c1d8ce94c48c242955ef10f1f2904962 (diff)
downloadandroid_external_selinux-28cf7ea80d067f070453d47a9a1881517f14d433.tar.gz
android_external_selinux-28cf7ea80d067f070453d47a9a1881517f14d433.tar.bz2
android_external_selinux-28cf7ea80d067f070453d47a9a1881517f14d433.zip
perfcrastination: Merge remote-tracking branch 'aosp/upstream-master' into mymerge
Followed the following steps: # In repo client cd external/selinux repo sync . repo start mymerge . git merge aosp/upstream-master --no-ff # resolve any conflicts repo upload . Test: device compiles and boots Change-Id: I2b5b1a201d43ee94fc909dd8bca5595bc7f0e522
Diffstat (limited to 'libselinux')
-rw-r--r--libselinux/src/selinux_restorecon.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libselinux/src/selinux_restorecon.c b/libselinux/src/selinux_restorecon.c
index 924d9538..5f189235 100644
--- a/libselinux/src/selinux_restorecon.c
+++ b/libselinux/src/selinux_restorecon.c
@@ -242,6 +242,8 @@ static int exclude_non_seclabel_mounts(void)
/* Check to see if the kernel supports seclabel */
if (uname(&uts) == 0 && strverscmp(uts.release, "2.6.30") < 0)
return 0;
+ if (is_selinux_enabled() <= 0)
+ return 0;
fp = fopen("/proc/mounts", "re");
if (!fp)