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

Side by Side Diff: net/socket/ssl_client_socket_pool.cc

Issue 1158193006: Converted bare pointer to scoped_ptr<> in net/socket and net/http (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed failed net unit tests Created 5 years, 6 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
« no previous file with comments | « net/socket/ssl_client_socket_pool.h ('k') | net/socket/transport_client_socket_pool.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "net/socket/ssl_client_socket_pool.h" 5 #include "net/socket/ssl_client_socket_pool.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/metrics/field_trial.h" 9 #include "base/metrics/field_trial.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after
610 int SSLClientSocketPool::IdleSocketCountInGroup( 610 int SSLClientSocketPool::IdleSocketCountInGroup(
611 const std::string& group_name) const { 611 const std::string& group_name) const {
612 return base_.IdleSocketCountInGroup(group_name); 612 return base_.IdleSocketCountInGroup(group_name);
613 } 613 }
614 614
615 LoadState SSLClientSocketPool::GetLoadState( 615 LoadState SSLClientSocketPool::GetLoadState(
616 const std::string& group_name, const ClientSocketHandle* handle) const { 616 const std::string& group_name, const ClientSocketHandle* handle) const {
617 return base_.GetLoadState(group_name, handle); 617 return base_.GetLoadState(group_name, handle);
618 } 618 }
619 619
620 base::DictionaryValue* SSLClientSocketPool::GetInfoAsValue( 620 scoped_ptr<base::DictionaryValue> SSLClientSocketPool::GetInfoAsValue(
621 const std::string& name, 621 const std::string& name,
622 const std::string& type, 622 const std::string& type,
623 bool include_nested_pools) const { 623 bool include_nested_pools) const {
624 base::DictionaryValue* dict = base_.GetInfoAsValue(name, type); 624 scoped_ptr<base::DictionaryValue> dict(base_.GetInfoAsValue(name, type));
625 if (include_nested_pools) { 625 if (include_nested_pools) {
626 base::ListValue* list = new base::ListValue(); 626 base::ListValue* list = new base::ListValue();
627 if (transport_pool_) { 627 if (transport_pool_) {
628 list->Append(transport_pool_->GetInfoAsValue("transport_socket_pool", 628 list->Append(transport_pool_->GetInfoAsValue("transport_socket_pool",
629 "transport_socket_pool", 629 "transport_socket_pool",
630 false)); 630 false));
631 } 631 }
632 if (socks_pool_) { 632 if (socks_pool_) {
633 list->Append(socks_pool_->GetInfoAsValue("socks_pool", 633 list->Append(socks_pool_->GetInfoAsValue("socks_pool",
634 "socks_pool", 634 "socks_pool",
635 true)); 635 true));
636 } 636 }
637 if (http_proxy_pool_) { 637 if (http_proxy_pool_) {
638 list->Append(http_proxy_pool_->GetInfoAsValue("http_proxy_pool", 638 list->Append(http_proxy_pool_->GetInfoAsValue("http_proxy_pool",
639 "http_proxy_pool", 639 "http_proxy_pool",
640 true)); 640 true));
641 } 641 }
642 dict->Set("nested_pools", list); 642 dict->Set("nested_pools", list);
643 } 643 }
644 return dict; 644 return dict.Pass();
645 } 645 }
646 646
647 base::TimeDelta SSLClientSocketPool::ConnectionTimeout() const { 647 base::TimeDelta SSLClientSocketPool::ConnectionTimeout() const {
648 return base_.ConnectionTimeout(); 648 return base_.ConnectionTimeout();
649 } 649 }
650 650
651 bool SSLClientSocketPool::IsStalled() const { 651 bool SSLClientSocketPool::IsStalled() const {
652 return base_.IsStalled(); 652 return base_.IsStalled();
653 } 653 }
654 654
(...skipping 10 matching lines...) Expand all
665 if (base_.CloseOneIdleSocket()) 665 if (base_.CloseOneIdleSocket())
666 return true; 666 return true;
667 return base_.CloseOneIdleConnectionInHigherLayeredPool(); 667 return base_.CloseOneIdleConnectionInHigherLayeredPool();
668 } 668 }
669 669
670 void SSLClientSocketPool::OnSSLConfigChanged() { 670 void SSLClientSocketPool::OnSSLConfigChanged() {
671 FlushWithError(ERR_NETWORK_CHANGED); 671 FlushWithError(ERR_NETWORK_CHANGED);
672 } 672 }
673 673
674 } // namespace net 674 } // namespace net
OLDNEW
« no previous file with comments | « net/socket/ssl_client_socket_pool.h ('k') | net/socket/transport_client_socket_pool.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698