Commit d81e7d7e authored by dcheng's avatar dcheng Committed by Commit bot

Remove implicit conversions from scoped_refptr to T* in base/

This patch was generated by running the rewrite_scoped_refptr clang tool
on a Linux build.

BUG=110610

Review URL: https://codereview.chromium.org/510563002

Cr-Commit-Position: refs/heads/master@{#292050}
parent a3a8c58e
...@@ -1786,7 +1786,7 @@ void TraceLog::FinishFlush(int generation) { ...@@ -1786,7 +1786,7 @@ void TraceLog::FinishFlush(int generation) {
void TraceLog::FlushCurrentThread(int generation) { void TraceLog::FlushCurrentThread(int generation) {
{ {
AutoLock lock(lock_); AutoLock lock(lock_);
if (!CheckGeneration(generation) || !flush_message_loop_proxy_) { if (!CheckGeneration(generation) || !flush_message_loop_proxy_.get()) {
// This is late. The corresponding flush has finished. // This is late. The corresponding flush has finished.
return; return;
} }
...@@ -1796,7 +1796,7 @@ void TraceLog::FlushCurrentThread(int generation) { ...@@ -1796,7 +1796,7 @@ void TraceLog::FlushCurrentThread(int generation) {
delete thread_local_event_buffer_.Get(); delete thread_local_event_buffer_.Get();
AutoLock lock(lock_); AutoLock lock(lock_);
if (!CheckGeneration(generation) || !flush_message_loop_proxy_ || if (!CheckGeneration(generation) || !flush_message_loop_proxy_.get() ||
thread_message_loops_.size()) thread_message_loops_.size())
return; return;
...@@ -1808,7 +1808,7 @@ void TraceLog::FlushCurrentThread(int generation) { ...@@ -1808,7 +1808,7 @@ void TraceLog::FlushCurrentThread(int generation) {
void TraceLog::OnFlushTimeout(int generation) { void TraceLog::OnFlushTimeout(int generation) {
{ {
AutoLock lock(lock_); AutoLock lock(lock_);
if (!CheckGeneration(generation) || !flush_message_loop_proxy_) { if (!CheckGeneration(generation) || !flush_message_loop_proxy_.get()) {
// Flush has finished before timeout. // Flush has finished before timeout.
return; return;
} }
......
...@@ -169,7 +169,7 @@ bool ImportantFileWriter::PostWriteTask(const std::string& data) { ...@@ -169,7 +169,7 @@ bool ImportantFileWriter::PostWriteTask(const std::string& data) {
// using PostTask() in the typical scenario below. // using PostTask() in the typical scenario below.
if (!on_next_successful_write_.is_null()) { if (!on_next_successful_write_.is_null()) {
return base::PostTaskAndReplyWithResult( return base::PostTaskAndReplyWithResult(
task_runner_, task_runner_.get(),
FROM_HERE, FROM_HERE,
MakeCriticalClosure( MakeCriticalClosure(
Bind(&ImportantFileWriter::WriteFileAtomically, path_, data)), Bind(&ImportantFileWriter::WriteFileAtomically, path_, data)),
......
This diff is collapsed.
...@@ -282,7 +282,7 @@ void JsonPrefStore::ReadPrefsAsync(ReadErrorDelegate* error_delegate) { ...@@ -282,7 +282,7 @@ void JsonPrefStore::ReadPrefsAsync(ReadErrorDelegate* error_delegate) {
// Weakly binds the read task so that it doesn't kick in during shutdown. // Weakly binds the read task so that it doesn't kick in during shutdown.
base::PostTaskAndReplyWithResult( base::PostTaskAndReplyWithResult(
sequenced_task_runner_, sequenced_task_runner_.get(),
FROM_HERE, FROM_HERE,
base::Bind(&ReadPrefsFromDisk, path_, alternate_path_), base::Bind(&ReadPrefsFromDisk, path_, alternate_path_),
base::Bind(&JsonPrefStore::OnFileRead, AsWeakPtr())); base::Bind(&JsonPrefStore::OnFileRead, AsWeakPtr()));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment