Don't let bmgr leave a restore session hanging on error

Specifically, don't wait for the RestoreObserver to be informed that the restore
has completed unless performRestore() ran.  We were winding up in a case where
bmgr was hanging forever waiting on a nonexistent restore process instead of
calling endRestoreSession().

Also improve the documentation, explicitly calling out the need to call
endRestoreSession() even if previous operations on the session were
unsuccessful.
This commit is contained in:
Christopher Tate
2009-08-10 16:13:47 -07:00
parent a1cbccd7b3
commit 0e0b4ae5bc
3 changed files with 17 additions and 8 deletions

View File

@@ -1725,6 +1725,8 @@ class BackupManagerService extends IBackupManager.Stub {
return 0;
}
}
Log.w(TAG, "Restore token " + Long.toHexString(token) + " not found");
return -1;
}