summaryrefslogtreecommitdiffstats
path: root/ui/app_list
diff options
context:
space:
mode:
authorxiyuan@chromium.org <xiyuan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-26 22:35:22 +0000
committerxiyuan@chromium.org <xiyuan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-06-26 22:35:22 +0000
commitc8ed48ae643d895323fb0c3f530f5550bb43446a (patch)
tree9876fe0530f838ac8538d135df8d218cf9216ac0 /ui/app_list
parent74d5446495a7cfbaba6ce1053f30f0d500c17a17 (diff)
downloadchromium_src-c8ed48ae643d895323fb0c3f530f5550bb43446a.zip
chromium_src-c8ed48ae643d895323fb0c3f530f5550bb43446a.tar.gz
chromium_src-c8ed48ae643d895323fb0c3f530f5550bb43446a.tar.bz2
app_list: Don't open NULL search result.
BUG=134686 TEST=Verify crash in issue 134686 no longer happens. One repro would be piggyback the "app-list-show-apps-only" flag and type a query that generates no result then hit enter. Review URL: https://chromiumcodereview.appspot.com/10677002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@144303 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/app_list')
-rw-r--r--ui/app_list/search_result_list_view.cc5
1 files changed, 3 insertions, 2 deletions
diff --git a/ui/app_list/search_result_list_view.cc b/ui/app_list/search_result_list_view.cc
index bf5ddf5..9d4f568 100644
--- a/ui/app_list/search_result_list_view.cc
+++ b/ui/app_list/search_result_list_view.cc
@@ -134,8 +134,9 @@ void SearchResultListView::ButtonPressed(views::Button* sender,
if (delegate_) {
const SearchResult* result =
static_cast<SearchResultView*>(sender)->result();
- DCHECK(result);
- delegate_->OpenResult(*result, event.flags());
+
+ if (result)
+ delegate_->OpenResult(*result, event.flags());
}
}