Properly return zero-count cursor from getMatrixCursor
Change-Id: I574528bf56b5a82ecbaab3d3501b26e7afb974ec
This commit is contained in:
parent
0698f4027f
commit
d9b251d23b
@ -525,6 +525,9 @@ public final class ContentCache extends LinkedHashMap<String, Cursor> {
|
||||
if (c != null) {
|
||||
// Make a new MatrixCursor with the requested columns
|
||||
MatrixCursor mc = new MatrixCursor(projection, 1);
|
||||
if (c.getCount() == 0) {
|
||||
return mc;
|
||||
}
|
||||
Object[] row = new Object[projection.length];
|
||||
if (values != null) {
|
||||
// Make a copy; we don't want to change the original
|
||||
|
Loading…
Reference in New Issue
Block a user