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

Side by Side Diff: components/domain_reliability/monitor.cc

Issue 1565303002: Change IPEndpoint::address() to return a net::IPAddress (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Android Created 4 years, 11 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/domain_reliability/monitor.h" 5 #include "components/domain_reliability/monitor.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 std::string status; 54 std::string status;
55 if (!GetDomainReliabilityBeaconStatus( 55 if (!GetDomainReliabilityBeaconStatus(
56 attempt.result, beacon_template.http_response_code, &status)) { 56 attempt.result, beacon_template.http_response_code, &status)) {
57 return scoped_ptr<DomainReliabilityBeacon>(); 57 return scoped_ptr<DomainReliabilityBeacon>();
58 } 58 }
59 59
60 scoped_ptr<DomainReliabilityBeacon> beacon( 60 scoped_ptr<DomainReliabilityBeacon> beacon(
61 new DomainReliabilityBeacon(beacon_template)); 61 new DomainReliabilityBeacon(beacon_template));
62 beacon->status = status; 62 beacon->status = status;
63 beacon->chrome_error = attempt.result; 63 beacon->chrome_error = attempt.result;
64 if (!attempt.endpoint.address().empty()) 64 if (!attempt.endpoint.address_number().empty())
65 beacon->server_ip = attempt.endpoint.ToString(); 65 beacon->server_ip = attempt.endpoint.ToString();
66 else 66 else
67 beacon->server_ip = ""; 67 beacon->server_ip = "";
68 return beacon; 68 return beacon;
69 } 69 }
70 70
71 } // namespace 71 } // namespace
72 72
73 DomainReliabilityMonitor::DomainReliabilityMonitor( 73 DomainReliabilityMonitor::DomainReliabilityMonitor(
74 const std::string& upload_reporter_string, 74 const std::string& upload_reporter_string,
(...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after
348 if (beacon) 348 if (beacon)
349 context_manager_.RouteBeacon(std::move(beacon)); 349 context_manager_.RouteBeacon(std::move(beacon));
350 } 350 }
351 351
352 base::WeakPtr<DomainReliabilityMonitor> 352 base::WeakPtr<DomainReliabilityMonitor>
353 DomainReliabilityMonitor::MakeWeakPtr() { 353 DomainReliabilityMonitor::MakeWeakPtr() {
354 return weak_factory_.GetWeakPtr(); 354 return weak_factory_.GetWeakPtr();
355 } 355 }
356 356
357 } // namespace domain_reliability 357 } // namespace domain_reliability
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698