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

Issue 3581008: Fix instances of passing raw pointers to RefCounted objects in tasks. (Closed)

Created:
10 years, 2 months ago by willchan no longer on Chromium
Modified:
9 years, 7 months ago
CC:
chromium-reviews, vrk (LEFT CHROMIUM), fbarchard, Alpha Left Google, ben+cc_chromium.org, Sergey Ulanov, Paweł Hajdan Jr., jam, dmac, darin-cc_chromium.org, awong, garykac, brettw-cc_chromium.org, scherkus (not reviewing)
Base URL:
http://src.chromium.org/git/chromium.git
Visibility:
Public.

Description

Fix instances of passing raw pointers to RefCounted objects in tasks. Some of these manually handled it correctly by using AddRef()/Release() pairs. I switched them to make_scoped_refptr() to be more consistent. This also makes them cleanup properly on MessageLoop shutdown if we start deleting tasks. BUG=28083 TEST=builds Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=61899

Patch Set 1 #

Total comments: 3

Patch Set 2 : Oops, I'm a dork. Fixed build error. #

Patch Set 3 : Use make_scoped_refptr. #

Patch Set 4 : Merge #

Unified diffs Side-by-side diffs Delta from patch set Stats (+183 lines, -100 lines) Patch
M chrome/browser/automation/automation_resource_message_filter.cc View 1 2 3 2 chunks +9 lines, -2 lines 0 comments Download
M chrome/browser/debugger/devtools_http_protocol_handler.cc View 4 chunks +4 lines, -4 lines 0 comments Download
M chrome/browser/download/download_file_manager.cc View 1 chunk +7 lines, -3 lines 0 comments Download
M chrome/browser/download/download_manager.cc View 1 2 3 4 chunks +18 lines, -7 lines 0 comments Download
M chrome/browser/download/save_file_manager.cc View 2 chunks +10 lines, -9 lines 0 comments Download
M chrome/browser/download/save_package.cc View 1 2 3 1 chunk +1 line, -2 lines 0 comments Download
M chrome/browser/importer/importer_unittest.cc View 2 chunks +20 lines, -8 lines 0 comments Download
M chrome/browser/in_process_webkit/dom_storage_dispatcher_host.cc View 1 chunk +11 lines, -3 lines 0 comments Download
M chrome/browser/notifications/desktop_notification_service_unittest.cc View 1 chunk +4 lines, -2 lines 0 comments Download
M chrome/browser/renderer_host/audio_renderer_host.cc View 1 chunk +30 lines, -15 lines 0 comments Download
M chrome/browser/renderer_host/save_file_resource_handler.cc View 1 chunk +2 lines, -2 lines 0 comments Download
M chrome/browser/safe_browsing/safe_browsing_service.cc View 2 chunks +5 lines, -6 lines 0 comments Download
M chrome/profile_import/profile_import_thread.h View 3 chunks +3 lines, -3 lines 0 comments Download
M chrome/profile_import/profile_import_thread.cc View 1 5 chunks +12 lines, -7 lines 0 comments Download
M chrome/service/service_process.cc View 1 2 3 1 chunk +6 lines, -2 lines 0 comments Download
M ipc/ipc_channel_proxy.cc View 1 2 2 chunks +11 lines, -10 lines 0 comments Download
M media/base/pipeline_impl.cc View 1 chunk +6 lines, -2 lines 0 comments Download
M media/filters/decoder_base.h View 1 chunk +9 lines, -4 lines 0 comments Download
M media/filters/ffmpeg_demuxer.cc View 1 chunk +5 lines, -2 lines 0 comments Download
M media/filters/ffmpeg_video_decoder.cc View 1 chunk +6 lines, -5 lines 0 comments Download
M media/filters/omx_video_decoder.cc View 1 chunk +1 line, -1 line 0 comments Download
M remoting/host/host_key_pair.cc View 1 chunk +3 lines, -1 line 0 comments Download

Messages

Total messages: 5 (0 generated)
willchan no longer on Chromium
10 years, 2 months ago (2010-10-01 19:00:24 UTC) #1
darin (slow to review)
Is it possible to somehow prevent NewRunnableMethod from accepting a parameter that extends from RefCounted{ThreadSafe}? ...
10 years, 2 months ago (2010-10-01 19:26:10 UTC) #2
willchan no longer on Chromium
Yes, I have a change to fix raw_scoped_refptr_mismatch_checker.h. That's how I caught all of these ...
10 years, 2 months ago (2010-10-01 19:34:29 UTC) #3
jamesr
On 2010/10/01 19:34:29, willchan wrote: > Yes, I have a change to fix raw_scoped_refptr_mismatch_checker.h. That's ...
10 years, 2 months ago (2010-10-01 19:37:42 UTC) #4
scherkus (not reviewing)
10 years, 2 months ago (2010-10-02 01:22:40 UTC) #5
media stuff looks good -- thanks for doing this!

in general the media code has explicit lifetimes and we've been trying to move
away from refcounting as we don't need it

Powered by Google App Engine
This is Rietveld 408576698