Merge "init: Fix restorecon for /metadata." am: 8a178c184f am: c5aca531a5

Change-Id: I52ade85cf346695f3fc089c303821f3f81b1d0e3
This commit is contained in:
Automerger Merge Worker 2020-03-17 00:18:16 +00:00
commit 109b59aaa0

View file

@ -539,9 +539,9 @@ void SelinuxRestoreContext() {
// adb remount, snapshot-based updates, and DSUs all create files during
// first-stage init.
selinux_android_restorecon("/metadata", SELINUX_ANDROID_RESTORECON_RECURSE);
selinux_android_restorecon(SnapshotManager::GetGlobalRollbackIndicatorPath().c_str(), 0);
selinux_android_restorecon("/metadata/gsi", SELINUX_ANDROID_RESTORECON_RECURSE |
SELINUX_ANDROID_RESTORECON_SKIP_SEHASH);
}
int SelinuxKlogCallback(int type, const char* fmt, ...) {