| Index: chrome/browser/ui/gtk/html_dialog_gtk.cc
|
| diff --git a/chrome/browser/ui/gtk/html_dialog_gtk.cc b/chrome/browser/ui/gtk/html_dialog_gtk.cc
|
| index f2b28842be6080333b5e530d300a224ebbcc757f..ff6945a9d6a4fc7e5c629701f978f4449594f104 100644
|
| --- a/chrome/browser/ui/gtk/html_dialog_gtk.cc
|
| +++ b/chrome/browser/ui/gtk/html_dialog_gtk.cc
|
| @@ -22,6 +22,10 @@ namespace browser {
|
|
|
| gfx::NativeWindow ShowHtmlDialog(gfx::NativeWindow parent, Profile* profile,
|
| HtmlDialogUIDelegate* delegate) {
|
| + // It's not always safe to display an html dialog with an off the record
|
| + // profile. If the last browser with that profile is closed it will go
|
| + // away.
|
| + DCHECK(!profile->IsOffTheRecord() || delegate->IsDialogModal());
|
| HtmlDialogGtk* html_dialog =
|
| new HtmlDialogGtk(profile, delegate, parent);
|
| return html_dialog->InitDialog();
|
|
|