libchromeos: Switch http Response to use streams Make the response data of an HTTP request to use stream interface. BUG=None TEST=`FEATURES=test emerge-link libchromeos` Change-Id: I4d0e427e90f154a83ffd75973b4c211a989c1993 Reviewed-on: https://chromium-review.googlesource.com/265068 Trybot-Ready: Alex Vakulenko <avakulenko@chromium.org> Tested-by: Alex Vakulenko <avakulenko@chromium.org> Reviewed-by: Christopher Wiley <wiley@chromium.org> Commit-Queue: Alex Vakulenko <avakulenko@chromium.org>
diff --git a/buffet/device_registration_info.cc b/buffet/device_registration_info.cc index c9da52b..9cf3579 100644 --- a/buffet/device_registration_info.cc +++ b/buffet/device_registration_info.cc
@@ -268,8 +268,8 @@ } std::unique_ptr<base::DictionaryValue> -DeviceRegistrationInfo::ParseOAuthResponse( - const chromeos::http::Response* response, chromeos::ErrorPtr* error) { +DeviceRegistrationInfo::ParseOAuthResponse(chromeos::http::Response* response, + chromeos::ErrorPtr* error) { int code = 0; auto resp = chromeos::http::ParseJsonResponse(response, &code, error); if (resp && code >= chromeos::http::status_code::BadRequest) {
diff --git a/buffet/device_registration_info.h b/buffet/device_registration_info.h index 389042b..1f4c05e 100644 --- a/buffet/device_registration_info.h +++ b/buffet/device_registration_info.h
@@ -162,7 +162,7 @@ // Parse the OAuth response, and sets registration status to // kInvalidCredentials if our registration is no longer valid. std::unique_ptr<base::DictionaryValue> ParseOAuthResponse( - const chromeos::http::Response* response, chromeos::ErrorPtr* error); + chromeos::http::Response* response, chromeos::ErrorPtr* error); // This attempts to open the XMPP channel. The XMPP channel needs to be // restarted anytime the access_token is refreshed.