summaryrefslogtreecommitdiffstats
path: root/core/java/android/app/Service.java
diff options
context:
space:
mode:
authorDavid 'Digit' Turner <digit@google.com>2010-04-12 16:11:15 -0700
committerDavid 'Digit' Turner <digit@google.com>2010-04-15 10:35:25 -0700
commit4f99e3c28449833b10ee23c538246847fdb6a498 (patch)
tree4df99abb8a1ff4aa74bacb6b943b71b5a5ac3531 /core/java/android/app/Service.java
parentfa22de7993f94d338330a888bdc2aeaaf857c719 (diff)
downloadframeworks_base-4f99e3c28449833b10ee23c538246847fdb6a498.zip
frameworks_base-4f99e3c28449833b10ee23c538246847fdb6a498.tar.gz
frameworks_base-4f99e3c28449833b10ee23c538246847fdb6a498.tar.bz2
Remove native binaries when an updated system application is upgraded through OTA.
The point of this patch is to deal with the following case: - A system application exists in the system partition. As such its native code lies under /system/lib - An upgrade for it is installed through Market and overrides the version on the system partition. This places its native libraries under /data/data/<pkgname>/lib/ - Finally, the system is upgraded through an OTA, with an even more recent of the system application. We thus must remove the Market package as well as the native libraries that are in <dataDir>/lib since the new versions in /system/lib will be more recent. The patch itself removes the files in <dataDir>/lib when such a situation is detected. Note that this directory is created by the PackageManager service and owned by the 'system' userID. The application cannot create files there so simply erasing the content of the directory is enough (and avoids reparsing the market package file to list the installed binaries). The patch also fixes a different issue which can be reproduced with: - have system app installed on /system partition - install an update (e.g. adb install -r Term.apk) - uninstall the update (e.g. adb uninstall com.android.term) the logcat shows that the PackageManager will unpack the native libraries from the original /system/app/Term.apk into <dataDir>/lib, while they already are in /system/lib. The patch fixes that too. Change-Id: I5dfe27b91b6b31972e9cd4c196d15c3692732127
Diffstat (limited to 'core/java/android/app/Service.java')
0 files changed, 0 insertions, 0 deletions