Fix a case that would leak connections if an exception happens
Change-Id: I9f50911344e04f22e15bf9ba0c95f4e1b1422923
This commit is contained in:
parent
ff1ee36cb5
commit
9fe8131c3f
|
@ -418,13 +418,13 @@ public abstract class EmailServiceStub extends IEmailService.Stub implements IEm
|
|||
if (localFolderCursor != null) {
|
||||
localFolderCursor.close();
|
||||
}
|
||||
if (store != null) {
|
||||
store.closeConnections();
|
||||
}
|
||||
// If we just created the inbox, sync it
|
||||
if (inboxId != -1) {
|
||||
startSync(inboxId, true, 0);
|
||||
}
|
||||
if (store != null) {
|
||||
store.closeConnections();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue