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

Issue 2249223003: Fix a crash in AutoplayUmaHelper when releasing visibility observer (Closed)

Created:
4 years, 4 months ago by Zhiqiang Zhang (Slow)
Modified:
4 years, 4 months ago
CC:
blink-reviews, blink-reviews-html_chromium.org, chromium-reviews, dglazkov+blink
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix a crash and possible memory leak in AutoplayUmaHelper There's a crash in AutoplayUmaHelper::onVisibilityChangedForVideoMutedPlayMethod(). It might be possible that the callback is called after the observer is released. This CL adds additional nullcheck to avoid the crash. This CL also fixes a possible memory leak by changing wrapPersistent to wrapWeakPersistent. BUG=638595 Committed: https://crrev.com/403b4008f974e12adcc9ba95036120cc299784fb Cr-Commit-Position: refs/heads/master@{#412574}

Patch Set 1 #

Patch Set 2 : wrapPersistent => wrapWeakPersistent #

Unified diffs Side-by-side diffs Delta from patch set Stats (+2 lines, -2 lines) Patch
M third_party/WebKit/Source/core/html/AutoplayUmaHelper.cpp View 1 2 chunks +2 lines, -2 lines 0 comments Download

Messages

Total messages: 14 (7 generated)
Zhiqiang Zhang (Slow)
PTAL. I don't have any other explanations for the crash. Maybe we should land this ...
4 years, 4 months ago (2016-08-17 15:17:20 UTC) #4
mlamouri (slow - plz ping)
On 2016/08/17 at 15:17:20, zqzhang wrote: > PTAL. I don't have any other explanations for ...
4 years, 4 months ago (2016-08-17 15:42:38 UTC) #5
Zhiqiang Zhang (Slow)
On 2016/08/17 15:42:38, Mounir Lamouri wrote: > On 2016/08/17 at 15:17:20, zqzhang wrote: > > ...
4 years, 4 months ago (2016-08-17 16:08:08 UTC) #6
mlamouri (slow - plz ping)
lgtm
4 years, 4 months ago (2016-08-17 16:11:45 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2249223003/20001
4 years, 4 months ago (2016-08-17 16:16:44 UTC) #10
commit-bot: I haz the power
Committed patchset #2 (id:20001)
4 years, 4 months ago (2016-08-17 17:29:18 UTC) #12
commit-bot: I haz the power
4 years, 4 months ago (2016-08-17 17:32:36 UTC) #14
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/403b4008f974e12adcc9ba95036120cc299784fb
Cr-Commit-Position: refs/heads/master@{#412574}

Powered by Google App Engine
This is Rietveld 408576698