Don't crash on transport unregistration if there is no current transport

Change-Id: Icd0962254ba224a7be27d408dffb25b634f67863
This commit is contained in:
Christopher Tate
2010-01-29 16:27:04 -08:00
parent 239d5b3638
commit b0dcaaf108

View File

@@ -641,7 +641,7 @@ class BackupManagerService extends IBackupManager.Stub {
mTransports.put(name, transport);
} else {
mTransports.remove(name);
if (mCurrentTransport.equals(name)) {
if ((mCurrentTransport != null) && mCurrentTransport.equals(name)) {
mCurrentTransport = null;
}
// Nothing further to do in the unregistration case