Index: chrome/browser/task_manager/task_manager_resource_providers.cc |
diff --git a/chrome/browser/task_manager/task_manager_resource_providers.cc b/chrome/browser/task_manager/task_manager_resource_providers.cc |
index ee35c315c5bbc78bdd79f344cef4cb0e44b1e7b4..6e2cff6b27c287a90300d7a053256064fe1347e8 100644 |
--- a/chrome/browser/task_manager/task_manager_resource_providers.cc |
+++ b/chrome/browser/task_manager/task_manager_resource_providers.cc |
@@ -285,11 +285,10 @@ string16 TaskManagerTabContentsResource::GetProfileName() const { |
ProfileInfoCache& cache = |
g_browser_process->profile_manager()->GetProfileInfoCache(); |
Profile* profile = tab_contents_->profile()->GetOriginalProfile(); |
- size_t index = cache.GetIndexOfProfileWithPath(profile->GetPath()); |
- if (index == std::string::npos) |
- return string16(); |
- else |
- return cache.GetNameOfProfileAtIndex(index); |
+ ProfileInfoEntry entry; |
+ if (cache.GetInfoForProfile(profile->GetPath(), &entry)) |
+ return entry.name(); |
+ return string16(); |
} |
SkBitmap TaskManagerTabContentsResource::GetIcon() const { |
@@ -1080,11 +1079,10 @@ string16 TaskManagerExtensionProcessResource::GetProfileName() const { |
ProfileInfoCache& cache = |
g_browser_process->profile_manager()->GetProfileInfoCache(); |
Profile* profile = extension_host_->profile()->GetOriginalProfile(); |
- size_t index = cache.GetIndexOfProfileWithPath(profile->GetPath()); |
- if (index == std::string::npos) |
- return string16(); |
- else |
- return cache.GetNameOfProfileAtIndex(index); |
+ ProfileInfoEntry entry; |
+ if (cache.GetInfoForProfile(profile->GetPath(), &entry)) |
+ return entry.name(); |
+ return string16(); |
} |
SkBitmap TaskManagerExtensionProcessResource::GetIcon() const { |