Index: chrome/browser/webui/chrome_url_data_manager_backend.cc |
diff --git a/chrome/browser/webui/chrome_url_data_manager_backend.cc b/chrome/browser/webui/chrome_url_data_manager_backend.cc |
index e484a052909d48530f5aa0a1d9f7df2bf21c6418..1f3d73bc874390ab887248f2b85f4bb904c63baa 100644 |
--- a/chrome/browser/webui/chrome_url_data_manager_backend.cc |
+++ b/chrome/browser/webui/chrome_url_data_manager_backend.cc |
@@ -178,8 +178,11 @@ void ChromeURLDataManagerBackend::AddDataSource( |
ChromeURLDataManager::DataSource* source) { |
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); |
DataSourceMap::iterator i = data_sources_.find(source->source_name()); |
- if (i != data_sources_.end()) |
+ if (i != data_sources_.end()) { |
+ if (!source->ShouldReplaceExistingSource()) |
+ return; |
i->second->backend_ = NULL; |
+ } |
data_sources_[source->source_name()] = source; |
source->backend_ = this; |
} |