system/core
Révision | d7d475d470de7bb291034d1d61ec832bc1d2bbbb (tree) |
---|---|
l'heure | 2019-07-16 11:55:21 |
Auteur | Daniel Rosenberg <drosen@goog...> |
Commiter | android-build-team Robot |
Reland "Revert "rootdir / sdcard : Stop creating /data/media/obb.""
This reverts commit 997a2d93d7a9216c248be9c983adec2d91283f5a.
Reason for revert: This revert is needed, just also need some selinux rules for changes to the script that runs if this folder is present.
Bug: 136199978
Change-Id: Ie0544954965e3c90abc2f833c41949976c3bea65
(cherry picked from commit 35708b9d7bcae0f9183de2848d782b2d0c54bcb6)
@@ -589,6 +589,7 @@ on post-fs-data | ||
589 | 589 | symlink /data/data /data/user/0 |
590 | 590 | |
591 | 591 | mkdir /data/media 0770 media_rw media_rw |
592 | + mkdir /data/media/obb 0770 media_rw media_rw | |
592 | 593 | |
593 | 594 | mkdir /data/cache 0770 system cache |
594 | 595 | mkdir /data/cache/recovery 0770 system cache |
@@ -214,14 +214,7 @@ static void run_sdcardfs(const std::string& source_path, const std::string& labe | ||
214 | 214 | |
215 | 215 | if (multi_user) { |
216 | 216 | std::string obb_path = source_path + "/obb"; |
217 | - // Only attempt to prepare the /obb dir if it already exists. We want | |
218 | - // the legacy obb path "/data/media/obb" to be fixed up so that we can | |
219 | - // migrate it to its new location, but we don't want the directory to be | |
220 | - // created if it doesn't already exist. | |
221 | - struct stat sb; | |
222 | - if (TEMP_FAILURE_RETRY(lstat(obb_path.c_str(), &sb)) == 0) { | |
223 | - fs_prepare_dir(obb_path.c_str(), 0775, uid, gid); | |
224 | - } | |
217 | + fs_prepare_dir(obb_path.c_str(), 0775, uid, gid); | |
225 | 218 | } |
226 | 219 | |
227 | 220 | exit(0); |