summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authornrqv63@motorola.com <nrqv63@motorola.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-21 19:20:38 +0000
committernrqv63@motorola.com <nrqv63@motorola.com@0039d316-1c4b-4281-b951-d872f2087c98>2011-10-21 19:20:38 +0000
commit77981db45d0e6e2367ce6e8bf341e512eb750cc2 (patch)
tree13a059ab58db0258547f132b31b7cfae7cc147fd
parent4252f6098889f2c5a8649d1688b269e53a51d42d (diff)
downloadchromium_src-77981db45d0e6e2367ce6e8bf341e512eb750cc2.zip
chromium_src-77981db45d0e6e2367ce6e8bf341e512eb750cc2.tar.gz
chromium_src-77981db45d0e6e2367ce6e8bf341e512eb750cc2.tar.bz2
Fix for memory leak 72698_b in both normal and incognito mode.Actually it was wrong to remove the whole suppression for this fix. The same suppression can be observed in incognito mode.
BUG=72698 TEST= open google.com in 1. normal mode. 2. Incognito mode. Review URL: http://codereview.chromium.org/8342068 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@106756 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/browser/profiles/off_the_record_profile_io_data.cc3
-rw-r--r--chrome/browser/profiles/off_the_record_profile_io_data.h1
-rw-r--r--chrome/browser/profiles/profile_impl_io_data.cc3
-rw-r--r--chrome/browser/profiles/profile_impl_io_data.h1
-rw-r--r--tools/valgrind/memcheck/suppressions.txt7
5 files changed, 6 insertions, 9 deletions
diff --git a/chrome/browser/profiles/off_the_record_profile_io_data.cc b/chrome/browser/profiles/off_the_record_profile_io_data.cc
index ca50761..1d27f0c 100644
--- a/chrome/browser/profiles/off_the_record_profile_io_data.cc
+++ b/chrome/browser/profiles/off_the_record_profile_io_data.cc
@@ -210,8 +210,9 @@ void OffTheRecordProfileIOData::LazyInitializeInternal(
main_http_factory_.reset(cache);
main_context->set_http_transaction_factory(cache);
- main_context->set_ftp_transaction_factory(
+ ftp_factory_.reset(
new net::FtpNetworkLayer(main_context->host_resolver()));
+ main_context->set_ftp_transaction_factory(ftp_factory_.get());
main_context->set_chrome_url_data_manager_backend(
chrome_url_data_manager_backend());
diff --git a/chrome/browser/profiles/off_the_record_profile_io_data.h b/chrome/browser/profiles/off_the_record_profile_io_data.h
index 52bffc6..15f1d93 100644
--- a/chrome/browser/profiles/off_the_record_profile_io_data.h
+++ b/chrome/browser/profiles/off_the_record_profile_io_data.h
@@ -105,6 +105,7 @@ class OffTheRecordProfileIOData : public ProfileIOData {
const std::string& app_id) const;
mutable scoped_ptr<net::HttpTransactionFactory> main_http_factory_;
+ mutable scoped_ptr<net::FtpTransactionFactory> ftp_factory_;
mutable scoped_ptr<net::HttpServerPropertiesImpl> http_server_properties_;
diff --git a/chrome/browser/profiles/profile_impl_io_data.cc b/chrome/browser/profiles/profile_impl_io_data.cc
index d6ef5ec..60807ac 100644
--- a/chrome/browser/profiles/profile_impl_io_data.cc
+++ b/chrome/browser/profiles/profile_impl_io_data.cc
@@ -393,8 +393,9 @@ void ProfileImplIOData::LazyInitializeInternal(
main_context->set_http_transaction_factory(main_cache);
media_request_context_->set_http_transaction_factory(media_cache);
- main_context->set_ftp_transaction_factory(
+ ftp_factory_.reset(
new net::FtpNetworkLayer(io_thread_globals->host_resolver.get()));
+ main_context->set_ftp_transaction_factory(ftp_factory_.get());
main_context->set_chrome_url_data_manager_backend(
chrome_url_data_manager_backend());
diff --git a/chrome/browser/profiles/profile_impl_io_data.h b/chrome/browser/profiles/profile_impl_io_data.h
index 417fa78..1c13eed 100644
--- a/chrome/browser/profiles/profile_impl_io_data.h
+++ b/chrome/browser/profiles/profile_impl_io_data.h
@@ -139,6 +139,7 @@ class ProfileImplIOData : public ProfileIOData {
mutable scoped_ptr<net::HttpTransactionFactory> main_http_factory_;
mutable scoped_ptr<net::HttpTransactionFactory> media_http_factory_;
+ mutable scoped_ptr<net::FtpTransactionFactory> ftp_factory_;
mutable scoped_ptr<chrome_browser_net::Predictor> predictor_;
mutable scoped_ptr<chrome_browser_net::HttpServerPropertiesManager>
diff --git a/tools/valgrind/memcheck/suppressions.txt b/tools/valgrind/memcheck/suppressions.txt
index de7f1ac..9dfb573 100644
--- a/tools/valgrind/memcheck/suppressions.txt
+++ b/tools/valgrind/memcheck/suppressions.txt
@@ -3147,13 +3147,6 @@
fun:_ZN13ProfileIOData20InitializeOnUIThreadEP7Profile
}
{
- bug_72698_b
- Memcheck:Leak
- fun:_Znw*
- ...
- fun:_ZNK13ProfileIOData14LazyInitializeEv
-}
-{
bug_73132
Memcheck:Leak
fun:_Znw*