am 3d521c0a: Merge "Perform post installation operations directly if backup manager is disabled" into lmp-mr1-dev

* commit '3d521c0a0165dfef53e3c9d3d562bc0ec45405a8':
  Perform post installation operations directly if backup manager is disabled
This commit is contained in:
Rubin Xu
2015-02-09 19:33:19 +00:00
committed by Android Git Automerger

View File

@@ -8636,7 +8636,11 @@ public class PackageManagerService extends IPackageManager.Stub {
if (DEBUG_INSTALL) Log.v(TAG, "token " + token
+ " to BM for possible restore");
try {
bm.restoreAtInstall(res.pkg.applicationInfo.packageName, token);
if (bm.isBackupServiceActive(UserHandle.USER_OWNER)) {
bm.restoreAtInstall(res.pkg.applicationInfo.packageName, token);
} else {
doRestore = false;
}
} catch (RemoteException e) {
// can't happen; the backup manager is local
} catch (Exception e) {