Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7568)

Unified Diff: chrome/renderer/render_view.cc

Issue 5658001: Work around for a crasher with the select popup on Mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Synced Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/render_view.cc
diff --git a/chrome/renderer/render_view.cc b/chrome/renderer/render_view.cc
index f5558ef2298ab4c953c753330097310bf6762047..458ff9c47cb9120e2a619e7684b3d013b0878e86 100644
--- a/chrome/renderer/render_view.cc
+++ b/chrome/renderer/render_view.cc
@@ -5683,6 +5683,14 @@ void RenderView::OnAsyncFileOpened(base::PlatformFileError error_code,
#if defined(OS_MACOSX)
void RenderView::OnSelectPopupMenuItem(int selected_index) {
+ if (external_popup_menu_ == NULL) {
+ // Crash reports from the field indicate that we can be notified with a
+ // NULL external popup menu (we probably get notified twice).
+ // If you hit this please file a bug against jcivelli and include the page
+ // and steps to repro.
+ NOTREACHED();
+ return;
+ }
external_popup_menu_->DidSelectItem(selected_index);
external_popup_menu_.reset();
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698