Automated import from //branches/master/...@141518,141518
This commit is contained in:
committed by
The Android Open Source Project
parent
013456784a
commit
eb785fa71a
@@ -253,7 +253,15 @@ public class SortCursor extends AbstractCursor
|
||||
if (mCursor != null) {
|
||||
return mCursor.getColumnNames();
|
||||
} else {
|
||||
return new String[0];
|
||||
// All of the cursors may be empty, but they can still return
|
||||
// this information.
|
||||
int length = mCursors.length;
|
||||
for (int i = 0 ; i < length ; i++) {
|
||||
if (mCursors[i] != null) {
|
||||
return mCursors[i].getColumnNames();
|
||||
}
|
||||
}
|
||||
throw new IllegalStateException("No cursor that can return names");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user