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

Unified Diff: chrome/browser/component_updater/pepper_flash_component_installer.cc

Issue 2109873002: Fix assert in Flash component install. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/component_updater/pepper_flash_component_installer.cc
diff --git a/chrome/browser/component_updater/pepper_flash_component_installer.cc b/chrome/browser/component_updater/pepper_flash_component_installer.cc
index 472e25c771a484231ef6cebc5811b37c436fd85c..88595a0a102d43db356ca9930e10a4c0b928a695 100644
--- a/chrome/browser/component_updater/pepper_flash_component_installer.cc
+++ b/chrome/browser/component_updater/pepper_flash_component_installer.cc
@@ -105,6 +105,14 @@ bool IsPepperFlash(const content::WebPluginInfo& plugin) {
(plugin.pepper_permissions & ppapi::PERMISSION_FLASH);
}
+void NotifyPathServiceAndChrome(const base::FilePath& path,
+ const Version& version) {
+ PathService::Override(chrome::DIR_PEPPER_FLASH_PLUGIN, path);
+ BrowserThread::PostTask(
+ BrowserThread::UI, FROM_HERE,
+ base::Bind(&RegisterPepperFlashWithChrome, path, version));
+}
+
void RegisterPepperFlashWithChrome(const base::FilePath& path,
const Version& version) {
DCHECK_CURRENTLY_ON(BrowserThread::UI);
@@ -226,9 +234,8 @@ void FlashComponentInstallerTraits::ComponentReady(
// Installation is done. Now tell the rest of chrome. Both the path service
// and to the plugin service. On Linux, a restart is required to use the new
// Flash version, so we do not do this.
- PathService::Override(chrome::DIR_PEPPER_FLASH_PLUGIN, path);
- RegisterPepperFlashWithChrome(path.Append(chrome::kPepperFlashPluginFilename),
- version);
+ BrowserThread::GetBlockingPool()->PostTask(
+ FROM_HERE, base::Bind(&NotifyPathServiceAndChrome, path, version));
#endif // !defined(OS_LINUX)
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698