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

Issue 2317483005: Clear LifecycleObserver::m_context when LifecycleObserver::contextDestroyed gets called (Closed)

Created:
4 years, 3 months ago by haraken
Modified:
4 years, 3 months ago
Reviewers:
dcheng
CC:
chromium-reviews, blink-reviews
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Clear LifecycleObserver::m_context when LifecycleObserver::contextDestroyed gets called This CL clears LifecycleObserver::m_context when LifecycleObserver::contextDestroyed gets called. This means that LifecycleObserver::context() starts returning false after the context gets destroyed. The new behavior makes a lot of more sense, but the problem is that some existing code is assuming that LifecycleObserver::context() keeps returning the context even after the context gets destroyed. This CL fixed the problematic code to make all layout tests pass, but I'm not sure if I've updated all of the problematic code (because the coverage of the layout tests is not sufficient). However, the worst thing that can happen is that code that had been assuming that LifecycleObserver::context() returns a context even after the context gets destroyed will stop working (it may cause a null-deref crash). I think the risk is low. BUG=610176 Committed: https://crrev.com/b729a998b05ec916731171d59de95e0aea31bbac Cr-Commit-Position: refs/heads/master@{#419951}

Patch Set 1 #

Patch Set 2 : temp #

Patch Set 3 : temp #

Patch Set 4 : temp #

Patch Set 5 : temp #

Patch Set 6 : temp #

Patch Set 7 : temp #

Patch Set 8 : temp #

Patch Set 9 : temp #

Patch Set 10 : temp #

Patch Set 11 : temp #

Total comments: 1

Messages

Total messages: 60 (46 generated)
haraken
PTAL I'll send a PSA before landing this CL because it may cause null-deref crashes ...
4 years, 3 months ago (2016-09-15 15:58:13 UTC) #43
dcheng
https://codereview.chromium.org/2317483005/diff/200001/third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp File third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp (right): https://codereview.chromium.org/2317483005/diff/200001/third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp#newcode654 third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp:654: throwForLoadFailureIfNeeded(exceptionState, "Document is already detached."); Is this something required ...
4 years, 3 months ago (2016-09-16 22:49:52 UTC) #44
haraken
On 2016/09/16 22:49:52, dcheng wrote: > https://codereview.chromium.org/2317483005/diff/200001/third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp > File third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp (right): > > https://codereview.chromium.org/2317483005/diff/200001/third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp#newcode654 > ...
4 years, 3 months ago (2016-09-16 23:41:18 UTC) #45
dcheng
On 2016/09/16 23:41:18, haraken wrote: > On 2016/09/16 22:49:52, dcheng wrote: > > > https://codereview.chromium.org/2317483005/diff/200001/third_party/WebKit/Source/core/xmlhttprequest/XMLHttpRequest.cpp ...
4 years, 3 months ago (2016-09-17 00:17:41 UTC) #46
haraken
On 2016/09/17 00:17:41, dcheng wrote: > On 2016/09/16 23:41:18, haraken wrote: > > On 2016/09/16 ...
4 years, 3 months ago (2016-09-17 00:47:00 UTC) #47
dcheng
OK, I see, this used to error out inside createRequest(), but that doesn't work because ...
4 years, 3 months ago (2016-09-17 06:12:54 UTC) #48
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/2317483005/200001
4 years, 3 months ago (2016-09-21 00:56:05 UTC) #51
commit-bot: I haz the power
Committed patchset #11 (id:200001)
4 years, 3 months ago (2016-09-21 02:22:58 UTC) #53
commit-bot: I haz the power
Patchset 11 (id:??) landed as https://crrev.com/b729a998b05ec916731171d59de95e0aea31bbac Cr-Commit-Position: refs/heads/master@{#419951}
4 years, 3 months ago (2016-09-21 02:25:11 UTC) #55
loyso (OOO)
Looks like this CL causes webkit_tests to fail on Linux https://build.chromium.org/p/chromium.webkit/builders/WebKit%20Linux%20Leak/builds/23104 https://build.chromium.org/p/chromium.webkit/builders/WebKit%20Linux%20Leak/builds/23105 Any ideas?
4 years, 3 months ago (2016-09-21 04:20:20 UTC) #56
haraken
On 2016/09/21 04:20:20, loyso wrote: > Looks like this CL causes webkit_tests to fail on ...
4 years, 3 months ago (2016-09-21 04:29:51 UTC) #57
haraken
On 2016/09/21 04:29:51, haraken wrote: > On 2016/09/21 04:20:20, loyso wrote: > > Looks like ...
4 years, 3 months ago (2016-09-21 04:40:47 UTC) #58
loyso (OOO)
On 2016/09/21 04:40:47, haraken wrote: > Landing a fix: https://codereview.chromium.org/2357833002/ Thanks for the prompt fix!
4 years, 3 months ago (2016-09-21 05:45:22 UTC) #59
dcheng
4 years, 3 months ago (2016-09-22 18:46:29 UTC) #60
Message was sent while issue was closed.
A revert of this CL (patchset #11 id:200001) has been created in
https://codereview.chromium.org/2365463004/ by dcheng@chromium.org.

The reason for reverting is: Speculatively reverting for
https://crbug.com/649272.

Powered by Google App Engine
This is Rietveld 408576698