| Index: net/http/http_server_properties_impl.cc
|
| diff --git a/net/http/http_server_properties_impl.cc b/net/http/http_server_properties_impl.cc
|
| index 2b00b893010837c5d8a282971ac585684894c33d..aec1ecc5ef7239f749404cb5e5d6ddbd680ec962 100644
|
| --- a/net/http/http_server_properties_impl.cc
|
| +++ b/net/http/http_server_properties_impl.cc
|
| @@ -407,9 +407,12 @@ bool HttpServerPropertiesImpl::SetAlternativeServices(
|
| AlternativeServiceMap::iterator it = alternative_service_map_.Peek(origin);
|
|
|
| if (alternative_service_info_vector.empty()) {
|
| - bool found = it != alternative_service_map_.end();
|
| - ClearAlternativeServices(origin);
|
| - return found;
|
| + RemoveCanonicalHost(origin);
|
| + if (it == alternative_service_map_.end())
|
| + return false;
|
| +
|
| + alternative_service_map_.Erase(it);
|
| + return true;
|
| }
|
|
|
| bool changed = true;
|
| @@ -508,17 +511,6 @@ void HttpServerPropertiesImpl::ConfirmAlternativeService(
|
| recently_broken_alternative_services_.erase(alternative_service);
|
| }
|
|
|
| -void HttpServerPropertiesImpl::ClearAlternativeServices(
|
| - const url::SchemeHostPort& origin) {
|
| - RemoveCanonicalHost(origin);
|
| -
|
| - AlternativeServiceMap::iterator it = alternative_service_map_.Peek(origin);
|
| - if (it == alternative_service_map_.end()) {
|
| - return;
|
| - }
|
| - alternative_service_map_.Erase(it);
|
| -}
|
| -
|
| const AlternativeServiceMap& HttpServerPropertiesImpl::alternative_service_map()
|
| const {
|
| return alternative_service_map_;
|
|
|