Start Magisk in SAR

This commit is contained in:
topjohnwu
2019-06-25 23:31:59 -07:00
parent a462435f2f
commit e29b712108
6 changed files with 67 additions and 38 deletions

View File

@@ -227,6 +227,10 @@ void restorecon() {
void restore_rootcon() {
setfilecon("/sbin", ROOT_CON);
setfilecon(MAGISKTMP, ROOT_CON);
setfilecon(MIRRDIR, ROOT_CON);
setfilecon(BLOCKDIR, ROOT_CON);
struct dirent *entry;
DIR *dir = xopendir("/sbin");
int dfd = dirfd(dir);