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

Unified Diff: ios/net/crn_http_protocol_handler.mm

Issue 2256193002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ios/net/cookies/cookie_store_ios_unittest.mm ('k') | ios/web/shell/shell_url_request_context_getter.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/net/crn_http_protocol_handler.mm
diff --git a/ios/net/crn_http_protocol_handler.mm b/ios/net/crn_http_protocol_handler.mm
index 845d19c2a7e3405b70b16ed4c1de57e5be010c1a..ed736375c7f125462c80ccff9265e1e4740dfedb 100644
--- a/ios/net/crn_http_protocol_handler.mm
+++ b/ios/net/crn_http_protocol_handler.mm
@@ -244,8 +244,8 @@ void HttpProtocolHandlerCore::HandleStreamEvent(NSStream* stream,
if (!post_data_readers_.empty()) {
// NOTE: This call will result in |post_data_readers_| being cleared,
// which is the desired behavior.
- net_request_->set_upload(base::WrapUnique(
- new ElementsUploadDataStream(std::move(post_data_readers_), 0)));
+ net_request_->set_upload(base::MakeUnique<ElementsUploadDataStream>(
+ std::move(post_data_readers_), 0));
DCHECK(post_data_readers_.empty());
}
net_request_->Start();
@@ -260,7 +260,7 @@ void HttpProtocolHandlerCore::HandleStreamEvent(NSStream* stream,
if (length) {
std::vector<char> owned_data(buffer_->data(), buffer_->data() + length);
post_data_readers_.push_back(
- base::WrapUnique(new UploadOwnedBytesElementReader(&owned_data)));
+ base::MakeUnique<UploadOwnedBytesElementReader>(&owned_data));
}
break;
}
« no previous file with comments | « ios/net/cookies/cookie_store_ios_unittest.mm ('k') | ios/web/shell/shell_url_request_context_getter.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698