diff options
author | Jean-Baptiste Queru <jbq@google.com> | 2010-11-22 13:40:29 -0800 |
---|---|---|
committer | Android Code Review <code-review@android.com> | 2010-11-22 13:40:29 -0800 |
commit | b2b0db2d5c89ae8824a4cb5d7944bae3a1dc8bf4 (patch) | |
tree | e3e8fa0eb97e182ccb9e444a5f7421fb0b006e46 | |
parent | e2ec61b23b6da2f6f0796939c3e00aa77bf17569 (diff) | |
parent | b00d41acd6bbef4fbdab17320b48e40258732465 (diff) | |
download | base-b2b0db2d5c89ae8824a4cb5d7944bae3a1dc8bf4.tar.gz |
Merge "SearchDialog: Fix for NullpointerException while using Suggestions in Browser"
-rw-r--r-- | core/java/android/app/SearchDialog.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/java/android/app/SearchDialog.java b/core/java/android/app/SearchDialog.java index 2fb746c3f2c1..9a3d6212fc8c 100644 --- a/core/java/android/app/SearchDialog.java +++ b/core/java/android/app/SearchDialog.java @@ -1107,6 +1107,9 @@ public class SearchDialog extends Dialog implements OnItemClickListener, OnItemS * @return true if a successful launch, false if could not (e.g. bad position). */ protected boolean launchSuggestion(int position, int actionKey, String actionMsg) { + if (mSuggestionsAdapter == null) { + return false; + } Cursor c = mSuggestionsAdapter.getCursor(); if ((c != null) && c.moveToPosition(position)) { |