summaryrefslogtreecommitdiffstats
path: root/rootdir
diff options
context:
space:
mode:
authorChia-chi Yeh <chiachi@android.com>2011-07-08 19:26:45 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-07-08 19:26:45 -0700
commit50d9819ef49c2d557ad0b33a7880a7a3b72e3fb8 (patch)
treeb1bc37edb522dfed8f99d6b908a8de47ac7369d6 /rootdir
parent8a330bc533691a5358168e9ccb24b615f1c8f42a (diff)
parentea7441415997faf34f7ae44f462f916f5f7ea0df (diff)
downloadsystem_core-50d9819ef49c2d557ad0b33a7880a7a3b72e3fb8.zip
system_core-50d9819ef49c2d557ad0b33a7880a7a3b72e3fb8.tar.gz
system_core-50d9819ef49c2d557ad0b33a7880a7a3b72e3fb8.tar.bz2
Merge "init: clean up init.rc as now mkdir handles EEXIST."
Diffstat (limited to 'rootdir')
-rw-r--r--rootdir/init.rc22
1 files changed, 4 insertions, 18 deletions
diff --git a/rootdir/init.rc b/rootdir/init.rc
index a2d9f18..d9ac7a4 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -115,11 +115,7 @@ on post-fs
chmod 0220 /proc/sysrq-trigger
# create the lost+found directories, so as to enforce our permissions
- mkdir /cache/lost+found 0770
-
- # double check the perms, in case lost+found already exists, and set owner
- chown root root /cache/lost+found
- chmod 0770 /cache/lost+found
+ mkdir /cache/lost+found 0770 root root
on post-fs-data
# We chown/chmod /data again so because mount is run as root + defaults
@@ -129,10 +125,7 @@ on post-fs-data
# Create dump dir and collect dumps.
# Do this before we mount cache so eventually we can use cache for
# storing dumps on platforms which do not have a dedicated dump partition.
-
- mkdir /data/dontpanic
- chown root log /data/dontpanic
- chmod 0750 /data/dontpanic
+ mkdir /data/dontpanic 0750 root log
# Collect apanic data, free resources and re-arm trigger
copy /proc/apanic_console /data/dontpanic/apanic_console
@@ -156,7 +149,6 @@ on post-fs-data
mkdir /data/misc/vpn/profiles 0770 system system
# give system access to wpa_supplicant.conf for backup and restore
mkdir /data/misc/wifi 0770 wifi wifi
- chmod 0770 /data/misc/wifi
chmod 0660 /data/misc/wifi/wpa_supplicant.conf
mkdir /data/local 0771 shell shell
mkdir /data/local/tmp 0771 shell shell
@@ -165,17 +157,11 @@ on post-fs-data
mkdir /data/app 0771 system system
mkdir /data/property 0700 root root
- # create dalvik-cache and double-check the perms
+ # create dalvik-cache, so as to enforce our permissions
mkdir /data/dalvik-cache 0771 system system
- chown system system /data/dalvik-cache
- chmod 0771 /data/dalvik-cache
# create the lost+found directories, so as to enforce our permissions
- mkdir /data/lost+found 0770
-
- # double check the perms, in case lost+found already exists, and set owner
- chown root root /data/lost+found
- chmod 0770 /data/lost+found
+ mkdir /data/lost+found 0770 root root
# create directory for DRM plug-ins
mkdir /data/drm 0774 drm drm