summaryrefslogtreecommitdiffstats
path: root/rootdir
diff options
context:
space:
mode:
authorNeil Fuller <nfuller@google.com>2015-03-31 18:24:29 +0100
committerNeil Fuller <nfuller@google.com>2015-04-13 11:38:32 +0100
commit08913228e17f4a16b6fbe77f9f08ca2a13323f5e (patch)
tree89956aff603e0506c8c2d884e79a8ce1985803c6 /rootdir
parentd67ff2d507add84a4d958bc19657e88d4689b92d (diff)
downloadsystem_core-08913228e17f4a16b6fbe77f9f08ca2a13323f5e.zip
system_core-08913228e17f4a16b6fbe77f9f08ca2a13323f5e.tar.gz
system_core-08913228e17f4a16b6fbe77f9f08ca2a13323f5e.tar.bz2
Executable to run on boot that removes old tzdata if needed
tzdatacheck is exec'd from init.rc early in boot just after /data is mounted. It checks to make sure that the tz rule data in /data is newer than the version in /system. If the data is older it is deleted. This is to address problems with earlier tz rule updates that occurred: after an OTA upgrade previous updates in /data would override newer versions in the system partition. Includes change to init.rc neccessary to run it at boot time. Other changes are in external/selinux. Bug: 19941636 Bug: https://code.google.com/p/android/issues/detail?id=35730 Change-Id: I7cc61e058424c856da88f11ff9b259f34cb39dc7
Diffstat (limited to 'rootdir')
-rw-r--r--rootdir/init.rc3
1 files changed, 3 insertions, 0 deletions
diff --git a/rootdir/init.rc b/rootdir/init.rc
index e6f4f4a..a2b8f59 100644
--- a/rootdir/init.rc
+++ b/rootdir/init.rc
@@ -321,6 +321,9 @@ on post-fs-data
# Set SELinux security contexts on upgrade or policy update.
restorecon_recursive /data
+ # Check any timezone data in /data is newer than the copy in /system, delete if not.
+ exec u:r:tzdatacheck:s0 system system -- /system/bin/tzdatacheck /system/usr/share/zoneinfo /data/misc/zoneinfo
+
# If there is no fs-post-data action in the init.<device>.rc file, you
# must uncomment this line, otherwise encrypted filesystems
# won't work.