Merge "Use selinux_android_setcon() instead of setcon()"
am: 64cc0825a6
* commit '64cc0825a639bf022b052cf4fa6aa3e8d13f61b1':
Use selinux_android_setcon() instead of setcon()
This commit is contained in:
commit
4692984e92
1 changed files with 2 additions and 2 deletions
|
@ -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";
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue