diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2018-02-27 21:06:05 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2018-02-27 21:06:05 +0000 |
commit | 82393b8382b39fbbf94cb2fcc7fc61b1cb62588d (patch) | |
tree | 2f3dce168d8d53abaeddd2ee9f6a19ce2ba0f774 /java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java | |
parent | 46cdf805e07c90ef54ead2a53e5b770e5a5928d1 (diff) | |
parent | a4a4df959c4163a99b43858c6f1cc50c403c644d (diff) |
Merge changes I09e8be0d,Ic94816e1
* changes:
Fix bug that soft keyboard pushes action bar out of window.
Added 2 null checks to fix top crashers.
Diffstat (limited to 'java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java')
-rw-r--r-- | java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java b/java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java index dbe11dd96..4d7ea3f3d 100644 --- a/java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java +++ b/java/com/android/dialer/searchfragment/directories/DirectoriesCursorLoader.java @@ -71,6 +71,11 @@ public final class DirectoriesCursorLoader extends CursorLoader { * @return A list of directories. */ public static List<Directory> toDirectories(Cursor cursor) { + if (cursor == null) { + LogUtil.i("DirectoriesCursorLoader.toDirectories", "Cursor was null"); + return new ArrayList<>(); + } + List<Directory> directories = new ArrayList<>(); cursor.moveToPosition(-1); while (cursor.moveToNext()) { |