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

Issue 202243003: Fix crashes in MemoryCache related to successful revalidation (Closed)

Created:
6 years, 9 months ago by Nate Chapin
Modified:
6 years, 9 months ago
Reviewers:
abarth-chromium
CC:
blink-reviews, gavinp+loader_chromium.org
Visibility:
Public.

Description

Fix crashes in MemoryCache related to successful revalidation If the same url is revalidated multiple times, the first revalidation may end up being incorrectly left in an LRU list after it is deleted. This is because we have an early exit in removeFromLRUList() when the resource's accessCount() is zero, even though we unconditionally put the resource in an LRU list when it is added to the cache. We increment accessCount for the new resources case in add(), but not the successful revalidation case in replace(). (All of these bugs are most likely the same root cause, but it's not absolutely certain) BUG=353035, 352538, 352444 TEST=MemoryCacheTest.MultipleReplace Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=169463

Patch Set 1 #

Patch Set 2 : Make mac builder happy #

Patch Set 3 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+25 lines, -8 lines) Patch
M Source/core/fetch/MemoryCache.cpp View 1 2 3 chunks +5 lines, -8 lines 0 comments Download
M Source/core/fetch/MemoryCacheTest.cpp View 1 1 chunk +20 lines, -0 lines 0 comments Download

Messages

Total messages: 23 (0 generated)
Nate Chapin
The test causes a use-after-free without the change in MemoryCache.cpp.
6 years, 9 months ago (2014-03-17 18:09:19 UTC) #1
abarth-chromium
lgtm
6 years, 9 months ago (2014-03-17 19:03:41 UTC) #2
Nate Chapin
The CQ bit was checked by japhet@chromium.org
6 years, 9 months ago (2014-03-17 19:04:37 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/japhet@chromium.org/202243003/1
6 years, 9 months ago (2014-03-17 19:04:47 UTC) #4
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-17 19:13:13 UTC) #5
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on mac_blink_compile_dbg
6 years, 9 months ago (2014-03-17 19:13:13 UTC) #6
Nate Chapin
The CQ bit was checked by japhet@chromium.org
6 years, 9 months ago (2014-03-17 19:42:44 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/japhet@chromium.org/202243003/20001
6 years, 9 months ago (2014-03-17 19:42:48 UTC) #8
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-17 19:43:54 UTC) #9
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on mac_blink_rel
6 years, 9 months ago (2014-03-17 19:43:55 UTC) #10
Nate Chapin
The CQ bit was checked by japhet@chromium.org
6 years, 9 months ago (2014-03-17 19:45:05 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/japhet@chromium.org/202243003/20001
6 years, 9 months ago (2014-03-17 19:45:16 UTC) #12
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-17 20:00:29 UTC) #13
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on linux_blink_dbg
6 years, 9 months ago (2014-03-17 20:00:30 UTC) #14
Nate Chapin
On 2014/03/17 19:03:41, abarth wrote: > lgtm Mind taking another quick look? I didn't test ...
6 years, 9 months ago (2014-03-17 21:51:32 UTC) #15
abarth-chromium
lgtm
6 years, 9 months ago (2014-03-17 23:43:49 UTC) #16
Nate Chapin
The CQ bit was checked by japhet@chromium.org
6 years, 9 months ago (2014-03-17 23:45:12 UTC) #17
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/japhet@chromium.org/202243003/40001
6 years, 9 months ago (2014-03-17 23:45:24 UTC) #18
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 9 months ago (2014-03-17 23:48:48 UTC) #19
commit-bot: I haz the power
Try jobs failed on following builders: tryserver.blink on blink_presubmit
6 years, 9 months ago (2014-03-17 23:48:49 UTC) #20
Nate Chapin
The CQ bit was checked by japhet@chromium.org
6 years, 9 months ago (2014-03-18 16:17:55 UTC) #21
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/japhet@chromium.org/202243003/40001
6 years, 9 months ago (2014-03-18 16:18:09 UTC) #22
commit-bot: I haz the power
6 years, 9 months ago (2014-03-18 19:12:32 UTC) #23
Message was sent while issue was closed.
Change committed as 169463

Powered by Google App Engine
This is Rietveld 408576698