Don't issue a deletion for the global metadata backup

We were accidentally submitting a deletion for the global metadata key in the
PM backup handling (it was falling into the usual "here's a package that we said
we'd backed up last time, but now it's no longer on device" code).  Don't do
that any more, i.e. actually keep the global metadata key in the backup set.
Oops.
This commit is contained in:
Christopher Tate
2009-06-29 18:52:55 -07:00
parent bbd63cb285
commit 6f317426e4

View File

@@ -120,7 +120,10 @@ public class PackageManagerBackupAgent extends BackupAgent {
// write its signature block to the output, keyed on the package name.
for (PackageInfo pkg : mAllPackages) {
String packName = pkg.packageName;
if (!existing.contains(packName)) {
if (packName.equals(GLOBAL_METADATA_KEY)) {
// We've already handled the metadata key; skip it here
continue;
} else if (!existing.contains(packName)) {
// We haven't stored this app's signatures yet, so we do that now
try {
PackageInfo info = mPackageManager.getPackageInfo(packName,