Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ffcdad9f authored by Bjorn Bringert's avatar Bjorn Bringert Committed by The Android Open Source Project
Browse files

am 544450b4: Fix NPE in SuggestionsAdapter when cursor is null.

Merge commit '544450b4'

* commit '544450b4':
  Fix NPE in SuggestionsAdapter when cursor is null.
parents 43cc2bac 544450b4
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -147,7 +147,7 @@ class SuggestionsAdapter extends ResourceCursorAdapter {
            final Cursor cursor = mSearchManager.getSuggestions(mSearchable, query);
            // trigger fill window so the spinner stays up until the results are copied over and
            // closer to being ready
            if (!mGlobalSearchMode) cursor.getCount();
            if (!mGlobalSearchMode && cursor != null) cursor.getCount();
            return cursor;
        } catch (RuntimeException e) {
            Log.w(LOG_TAG, "Search suggestions query threw an exception.", e);