OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "remoting/host/gcd_rest_client.h" | 5 #include "remoting/host/gcd_rest_client.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/json/json_writer.h" | 8 #include "base/json/json_writer.h" |
| 9 #include "base/message_loop/message_loop.h" |
| 10 #include "base/thread_task_runner_handle.h" |
9 #include "base/time/default_clock.h" | 11 #include "base/time/default_clock.h" |
10 #include "base/values.h" | 12 #include "base/values.h" |
11 #include "net/url_request/url_fetcher.h" | 13 #include "net/url_request/url_fetcher.h" |
12 #include "remoting/base/logging.h" | 14 #include "remoting/base/logging.h" |
13 | 15 |
14 namespace remoting { | 16 namespace remoting { |
15 | 17 |
16 // Only 'patchState' requests are supported at the moment, but other | 18 // Only 'patchState' requests are supported at the moment, but other |
17 // types of requests may be added in the future. | 19 // types of requests may be added in the future. |
18 struct GcdRestClient::PatchStateRequest { | 20 struct GcdRestClient::PatchStateRequest { |
(...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
162 << ") fetching URL: " << request_url; | 164 << ") fetching URL: " << request_url; |
163 status = NETWORK_ERROR; | 165 status = NETWORK_ERROR; |
164 } else { | 166 } else { |
165 LOG(ERROR) << "Error (" << response << ") fetching URL: " << request_url; | 167 LOG(ERROR) << "Error (" << response << ") fetching URL: " << request_url; |
166 } | 168 } |
167 | 169 |
168 FinishCurrentRequest(status); | 170 FinishCurrentRequest(status); |
169 } | 171 } |
170 | 172 |
171 } // namespace remoting | 173 } // namespace remoting |
OLD | NEW |