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

Side by Side Diff: components/component_updater/component_patcher.cc

Issue 505203003: Remove implicit conversions from scoped_refptr to T* in components/component_updater/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | components/component_updater/default_component_installer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "components/component_updater/component_patcher.h" 5 #include "components/component_updater/component_patcher.h"
6 6
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 } 84 }
85 const base::DictionaryValue* command_args = 85 const base::DictionaryValue* command_args =
86 static_cast<base::DictionaryValue*>(*next_command_); 86 static_cast<base::DictionaryValue*>(*next_command_);
87 87
88 std::string operation; 88 std::string operation;
89 if (command_args->GetString(kOp, &operation)) { 89 if (command_args->GetString(kOp, &operation)) {
90 current_operation_ = 90 current_operation_ =
91 CreateDeltaUpdateOp(operation, out_of_process_patcher_); 91 CreateDeltaUpdateOp(operation, out_of_process_patcher_);
92 } 92 }
93 93
94 if (!current_operation_) { 94 if (!current_operation_.get()) {
95 DonePatching(ComponentUnpacker::kDeltaUnsupportedCommand, 0); 95 DonePatching(ComponentUnpacker::kDeltaUnsupportedCommand, 0);
96 return; 96 return;
97 } 97 }
98 current_operation_->Run(command_args, 98 current_operation_->Run(command_args,
99 input_dir_, 99 input_dir_,
100 unpack_dir_, 100 unpack_dir_,
101 installer_, 101 installer_,
102 base::Bind(&ComponentPatcher::DonePatchingFile, 102 base::Bind(&ComponentPatcher::DonePatchingFile,
103 scoped_refptr<ComponentPatcher>(this)), 103 scoped_refptr<ComponentPatcher>(this)),
104 task_runner_); 104 task_runner_);
(...skipping 11 matching lines...) Expand all
116 116
117 void ComponentPatcher::DonePatching(ComponentUnpacker::Error error, 117 void ComponentPatcher::DonePatching(ComponentUnpacker::Error error,
118 int extended_error) { 118 int extended_error) {
119 current_operation_ = NULL; 119 current_operation_ = NULL;
120 task_runner_->PostTask(FROM_HERE, 120 task_runner_->PostTask(FROM_HERE,
121 base::Bind(callback_, error, extended_error)); 121 base::Bind(callback_, error, extended_error));
122 callback_.Reset(); 122 callback_.Reset();
123 } 123 }
124 124
125 } // namespace component_updater 125 } // namespace component_updater
OLDNEW
« no previous file with comments | « no previous file | components/component_updater/default_component_installer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698