Merge "Exclude /mnt/vendor from vold's ownership." into pi-dev

This commit is contained in:
TreeHugger Robot 2018-04-17 19:16:55 +00:00 committed by Android (Google) Code Review
commit b244714eea

View file

@ -623,8 +623,9 @@ int VolumeManager::unmountAll() {
mntent* mentry;
while ((mentry = getmntent(fp)) != NULL) {
auto test = std::string(mentry->mnt_dir);
if (android::base::StartsWith(test, "/mnt/")
|| android::base::StartsWith(test, "/storage/")) {
if ((android::base::StartsWith(test, "/mnt/") &&
!android::base::StartsWith(test, "/mnt/vendor")) ||
android::base::StartsWith(test, "/storage/")) {
toUnmount.push_front(test);
}
}