Index: components/proximity_auth/device_to_device_authenticator.cc |
diff --git a/components/proximity_auth/device_to_device_authenticator.cc b/components/proximity_auth/device_to_device_authenticator.cc |
index 30d88bbe04bb0c6ab65c888b6e8ca2f51065eacb..4dbe7fd5ce36c8e4aa0af8677f0cab840c160556 100644 |
--- a/components/proximity_auth/device_to_device_authenticator.cc |
+++ b/components/proximity_auth/device_to_device_authenticator.cc |
@@ -92,7 +92,7 @@ void DeviceToDeviceAuthenticator::OnKeyPairGenerated( |
} |
std::unique_ptr<base::Timer> DeviceToDeviceAuthenticator::CreateTimer() { |
- return base::WrapUnique(new base::OneShotTimer()); |
+ return base::MakeUnique<base::OneShotTimer>(); |
} |
void DeviceToDeviceAuthenticator::OnHelloMessageCreated( |
@@ -115,7 +115,7 @@ void DeviceToDeviceAuthenticator::OnHelloMessageCreated( |
hello_message_ = message; |
std::string permit_id = kPermitIdPrefix + account_id_; |
connection_->SendMessage( |
- base::WrapUnique(new WireMessage(hello_message_, permit_id))); |
+ base::MakeUnique<WireMessage>(hello_message_, permit_id)); |
} |
void DeviceToDeviceAuthenticator::OnResponderAuthTimedOut() { |
@@ -154,7 +154,7 @@ void DeviceToDeviceAuthenticator::OnInitiatorAuthCreated( |
} |
state_ = State::SENT_INITIATOR_AUTH; |
- connection_->SendMessage(base::WrapUnique(new WireMessage(message))); |
+ connection_->SendMessage(base::MakeUnique<WireMessage>(message)); |
} |
void DeviceToDeviceAuthenticator::Fail(const std::string& error_message) { |
@@ -181,9 +181,9 @@ void DeviceToDeviceAuthenticator::Succeed() { |
connection_->RemoveObserver(this); |
callback_.Run( |
Result::SUCCESS, |
- base::WrapUnique(new DeviceToDeviceSecureContext( |
+ base::MakeUnique<DeviceToDeviceSecureContext>( |
std::move(secure_message_delegate_), session_symmetric_key_, |
- responder_auth_message_, SecureContext::PROTOCOL_VERSION_THREE_ONE))); |
+ responder_auth_message_, SecureContext::PROTOCOL_VERSION_THREE_ONE)); |
} |
void DeviceToDeviceAuthenticator::OnConnectionStatusChanged( |