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

Commit 4692984e authored by Tom Cherry's avatar Tom Cherry Committed by android-build-merger
Browse files

Merge "Use selinux_android_setcon() instead of setcon()"

am: 64cc0825

* commit '64cc0825':
  Use selinux_android_setcon() instead of setcon()
parents 9526f21b 64cc0825
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -29,7 +29,7 @@
#include <android-base/stringprintf.h>
#include "cutils/properties.h"
#include "private/android_filesystem_config.h"
#include "selinux/selinux.h"
#include "selinux/android.h"

#include "adb.h"
#include "adb_auth.h"
@@ -137,7 +137,7 @@ static void drop_privileges(int server_port) {
        D("Local port disabled");
    } else {
        if (root_seclabel != nullptr) {
            if (setcon(root_seclabel) < 0) {
            if (selinux_android_setcon(root_seclabel) < 0) {
                LOG(FATAL) << "Could not set SELinux context";
            }
        }