am b8eb1cb7: Be sure to include shared lib path info when dealing with agents
Merge commit 'b8eb1cb79b2912b91a1b0198ba3e61776af07a79' into eclair-plus-aosp * commit 'b8eb1cb79b2912b91a1b0198ba3e61776af07a79': Be sure to include shared lib path info when dealing with agents
This commit is contained in:
@@ -649,11 +649,21 @@ class BackupManagerService extends IBackupManager.Stub {
|
|||||||
int N = packages.size();
|
int N = packages.size();
|
||||||
for (int a = N-1; a >= 0; a--) {
|
for (int a = N-1; a >= 0; a--) {
|
||||||
PackageInfo pkg = packages.get(a);
|
PackageInfo pkg = packages.get(a);
|
||||||
ApplicationInfo app = pkg.applicationInfo;
|
try {
|
||||||
if (((app.flags&ApplicationInfo.FLAG_ALLOW_BACKUP) == 0)
|
ApplicationInfo app = pkg.applicationInfo;
|
||||||
|| app.backupAgentName == null
|
if (((app.flags&ApplicationInfo.FLAG_ALLOW_BACKUP) == 0)
|
||||||
|| (mPackageManager.checkPermission(android.Manifest.permission.BACKUP_DATA,
|
|| app.backupAgentName == null
|
||||||
pkg.packageName) != PackageManager.PERMISSION_GRANTED)) {
|
|| (mPackageManager.checkPermission(android.Manifest.permission.BACKUP_DATA,
|
||||||
|
pkg.packageName) != PackageManager.PERMISSION_GRANTED)) {
|
||||||
|
packages.remove(a);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
// we will need the shared library path, so look that up and store it here
|
||||||
|
app = mPackageManager.getApplicationInfo(pkg.packageName,
|
||||||
|
PackageManager.GET_SHARED_LIBRARY_FILES);
|
||||||
|
pkg.applicationInfo.sharedLibraryFiles = app.sharedLibraryFiles;
|
||||||
|
}
|
||||||
|
} catch (NameNotFoundException e) {
|
||||||
packages.remove(a);
|
packages.remove(a);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user