Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d8fa5860 authored by Stephen Smalley's avatar Stephen Smalley
Browse files

Convert all selinux_android_restorecon and _setfilecon calls to new API.



libselinux selinux_android_restorecon API is changing to the more
general interface with flags and dropping the older variants.

Also get rid of the old, no longer used selinux_android_setfilecon API
and rename selinux_android_setfilecon2 to it as it is the only API in use.

Change-Id: I1e71ec398ccdc24cac4ec76f1b858d0f680f4925
Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
parent 449273e2
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -415,7 +415,7 @@ static jboolean native_restorecon(JNIEnv *env, jobject, jstring pathnameStr) {
        return false;
    }

    int ret = selinux_android_restorecon(pathname.c_str());
    int ret = selinux_android_restorecon(pathname.c_str(), 0);
    ALOGV("restorecon(%s) => %d", pathname.c_str(), ret);
    return (ret == 0);
}