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

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

Call selinux_status_open() prior to use of selinux_status_updated().



The selinux_status_*() interfaces require calling selinux_status_open()
first.  Since this was not being called by servicemanager, the
selinux_status_updated() call was always failing and servicemanager
was not reloading service_contexts upon a policy reload.

Change-Id: I6ac62e114bbca99c5f0999feb918fcde15009274
Signed-off-by: default avatarStephen Smalley <sds@tycho.nsa.gov>
parent 8980e0cc
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -361,6 +361,7 @@ int main(int argc, char **argv)

    selinux_enabled = is_selinux_enabled();
    sehandle = selinux_android_service_context_handle();
    selinux_status_open(true);

    if (selinux_enabled > 0) {
        if (sehandle == NULL) {