Prevent touching closed cursor

Bug: 4595568
Change-Id: Ic3087dc5f194aa879a3fea9d45fe77a1e285bde0
This commit is contained in:
Ben Komalo 2011-07-21 13:01:31 -07:00
parent 9d0bb2e3a0
commit 87d8ab4bb4

View File

@ -210,7 +210,7 @@ class MailboxFragmentAdapter extends CursorAdapter {
private boolean isHeader(int position) { private boolean isHeader(int position) {
Cursor c = getCursor(); Cursor c = getCursor();
if (c == null) { if ((c == null) || c.isClosed()) {
return false; return false;
} }
c.moveToPosition(position); c.moveToPosition(position);