Commit d941f305 authored by Allan Sandfeld Jensen's avatar Allan Sandfeld Jensen Committed by Commit Bot

Do not take references of temporary objects

Some compilers are less forgiving about this than clang.

Change-Id: Iad07f21fcc38b8701c7c05609048805114d2ef44
Reviewed-on: https://chromium-review.googlesource.com/c/1201854
Commit-Queue: Kim Paulhamus <kpaulhamus@chromium.org>
Reviewed-by: default avatarKim Paulhamus <kpaulhamus@chromium.org>
Cr-Commit-Position: refs/heads/master@{#632752}
parent b64517b3
......@@ -58,7 +58,7 @@ void U2fRegisterOperation::TryRegistration(bool is_duplicate_registration) {
void U2fRegisterOperation::OnRegisterResponseReceived(
bool is_duplicate_registration,
base::Optional<std::vector<uint8_t>> device_response) {
const auto& apdu_response =
const auto apdu_response =
device_response
? apdu::ApduResponse::CreateFromMessage(std::move(*device_response))
: base::nullopt;
......@@ -103,7 +103,7 @@ void U2fRegisterOperation::OnRegisterResponseReceived(
void U2fRegisterOperation::OnCheckForExcludedKeyHandle(
ExcludeListIterator it,
base::Optional<std::vector<uint8_t>> device_response) {
const auto& apdu_response =
const auto apdu_response =
device_response
? apdu::ApduResponse::CreateFromMessage(std::move(*device_response))
: base::nullopt;
......
......@@ -130,7 +130,7 @@ void U2fSignOperation::OnCheckForKeyHandlePresence(
AllowedListIterator it,
base::Optional<std::vector<uint8_t>> device_response) {
DCHECK(request().allow_list());
const auto& apdu_response =
const auto apdu_response =
device_response
? apdu::ApduResponse::CreateFromMessage(std::move(*device_response))
: base::nullopt;
......
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