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

Issue 1830383002: Fix thread safety issues with //components/upload_list. (Closed)

Created:
4 years, 9 months ago by Robert Sesek
Modified:
4 years, 8 months ago
Reviewers:
Mark Mentovai, Nico
CC:
chromium-reviews
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Fix thread safety issues with //components/upload_list. The uploads_ vector can be accessed simultaneously from multiple threads, which can lead to heap corruption. This change ensures access to uploads_ only on the creator task runner. Updates occur by currying the new data vector in a Closure across threads. BUG=597384 Committed: https://crrev.com/6221751958a5f073b9557cfb89ba7a4197a5369d Cr-Commit-Position: refs/heads/master@{#383495}

Patch Set 1 : #

Patch Set 2 : #

Patch Set 3 : Add race condition test #

Total comments: 9

Patch Set 4 : Address comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+204 lines, -124 lines) Patch
M chrome/browser/crash_upload_list_crashpad.h View 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/crash_upload_list_crashpad.cc View 1 2 chunks +3 lines, -3 lines 0 comments Download
M components/upload_list/BUILD.gn View 1 1 chunk +1 line, -0 lines 0 comments Download
M components/upload_list/upload_list.h View 1 2 3 2 chunks +15 lines, -22 lines 0 comments Download
M components/upload_list/upload_list.cc View 1 2 3 4 chunks +16 lines, -22 lines 0 comments Download
M components/upload_list/upload_list_unittest.cc View 1 2 6 chunks +168 lines, -76 lines 0 comments Download

Messages

Total messages: 19 (9 generated)
Robert Sesek
4 years, 9 months ago (2016-03-25 16:32:42 UTC) #6
Mark Mentovai
LGTM. Nice work. https://codereview.chromium.org/1830383002/diff/100001/components/upload_list/upload_list.cc File components/upload_list/upload_list.cc (right): https://codereview.chromium.org/1830383002/diff/100001/components/upload_list/upload_list.cc#newcode64 components/upload_list/upload_list.cc:64: std::move(uploads))); #include <utility> https://codereview.chromium.org/1830383002/diff/100001/components/upload_list/upload_list.cc#newcode119 components/upload_list/upload_list.cc:119: void ...
4 years, 9 months ago (2016-03-25 18:26:56 UTC) #7
Robert Sesek
https://codereview.chromium.org/1830383002/diff/100001/components/upload_list/upload_list.cc File components/upload_list/upload_list.cc (right): https://codereview.chromium.org/1830383002/diff/100001/components/upload_list/upload_list.cc#newcode64 components/upload_list/upload_list.cc:64: std::move(uploads))); On 2016/03/25 18:26:56, Mark Mentovai wrote: > #include ...
4 years, 9 months ago (2016-03-25 18:45:56 UTC) #8
Mark Mentovai
LGTM P.S. Thanks for giving the methods more rational names too.
4 years, 9 months ago (2016-03-25 18:48:40 UTC) #9
Robert Sesek
+jochen for OWNERS
4 years, 9 months ago (2016-03-25 21:30:32 UTC) #11
Robert Sesek
Since jochen is slow, +thakis for //chrome OWNERS
4 years, 8 months ago (2016-03-28 14:52:16 UTC) #13
Nico
INSTANT lgtm for chrome/
4 years, 8 months ago (2016-03-28 14:53:42 UTC) #14
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1830383002/120001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1830383002/120001
4 years, 8 months ago (2016-03-28 15:02:07 UTC) #16
commit-bot: I haz the power
Committed patchset #4 (id:120001)
4 years, 8 months ago (2016-03-28 15:41:51 UTC) #17
commit-bot: I haz the power
4 years, 8 months ago (2016-03-28 15:43:30 UTC) #19
Message was sent while issue was closed.
Patchset 4 (id:??) landed as
https://crrev.com/6221751958a5f073b9557cfb89ba7a4197a5369d
Cr-Commit-Position: refs/heads/master@{#383495}

Powered by Google App Engine
This is Rietveld 408576698