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

Issue 5958016: Fix crash when user presses send report before onload handler was called (Closed)

Created:
9 years, 12 months ago by Dmitry Polukhin
Modified:
9 years, 7 months ago
Reviewers:
rkc
CC:
chromium-reviews, inferno
Visibility:
Public.

Description

Fix crash when user presses send report before onload handler was called Crash dump from the bug shows that crash happened during call "bug_report_->UpdateData(...)" that was inlined into HandleSendReport. It looks like bug_report_ is NULL. bug_report_ is initialized with new object in HandleGetDialogDefaults that is called from JavaScript in window onload handler. So it looks like user clicked on send report button before the page is loaded and onload handler was called. BUG=chromium-os:10240 TEST=none Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=70264

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+5 lines, -0 lines) Patch
M chrome/browser/dom_ui/bug_report_ui.cc View 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 4 (0 generated)
Dmitry Polukhin
9 years, 12 months ago (2010-12-29 15:41:44 UTC) #1
rkc
On 2010/12/29 15:41:44, Dmitry Polukhin wrote: Doesn't this, http://codereview.chromium.org/6066002/ fix the same issue?
9 years, 12 months ago (2010-12-29 16:19:26 UTC) #2
Dmitry Polukhin
http://codereview.chromium.org/6066002 was about similar issue but not the same. In my case bug_report_ is NULL ...
9 years, 12 months ago (2010-12-29 17:40:09 UTC) #3
rkc
9 years, 12 months ago (2010-12-29 17:54:35 UTC) #4
Can't hurt to have the check anyway.
LGTM

On 2010/12/29 17:40:09, Dmitry Polukhin wrote:
> http://codereview.chromium.org/6066002 was about similar issue but not the
same.
> In my case bug_report_ is NULL i.e. it is used before it was initialized with
> new object. onload is called relatively late from JavaScript so user may have
> chance to do something and it is dangerous to assume that JavaScript will call
> function in some order (it should be checked explicit).

Powered by Google App Engine
This is Rietveld 408576698