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

Side by Side Diff: webkit/glue/plugins/plugin_list.cc

Issue 8179: Disable the yahoo application state plugin as it crashes the plugin process... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 12 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 <algorithm> 5 #include <algorithm>
6 #include <tchar.h> 6 #include <tchar.h>
7 7
8 #include "webkit/glue/plugins/plugin_list.h" 8 #include "webkit/glue/plugins/plugin_list.h"
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 24 matching lines...) Expand all
35 static const TCHAR kRegistryAcrobatReader[] = _T("AcroRd32.exe"); 35 static const TCHAR kRegistryAcrobatReader[] = _T("AcroRd32.exe");
36 static const TCHAR kRegistryWindowsMedia[] = _T("wmplayer.exe"); 36 static const TCHAR kRegistryWindowsMedia[] = _T("wmplayer.exe");
37 static const TCHAR kRegistryQuickTime[] = _T("QuickTimePlayer.exe"); 37 static const TCHAR kRegistryQuickTime[] = _T("QuickTimePlayer.exe");
38 static const TCHAR kRegistryPath[] = _T("Path"); 38 static const TCHAR kRegistryPath[] = _T("Path");
39 static const TCHAR kRegistryMozillaPlugins[] = _T("SOFTWARE\\MozillaPlugins"); 39 static const TCHAR kRegistryMozillaPlugins[] = _T("SOFTWARE\\MozillaPlugins");
40 static const TCHAR kRegistryFirefoxInstalled[] = 40 static const TCHAR kRegistryFirefoxInstalled[] =
41 _T("SOFTWARE\\Mozilla\\Mozilla Firefox"); 41 _T("SOFTWARE\\Mozilla\\Mozilla Firefox");
42 static const TCHAR kMozillaActiveXPlugin[] = _T("npmozax.dll"); 42 static const TCHAR kMozillaActiveXPlugin[] = _T("npmozax.dll");
43 static const TCHAR kNewWMPPlugin[] = _T("np-mswmp.dll"); 43 static const TCHAR kNewWMPPlugin[] = _T("np-mswmp.dll");
44 static const TCHAR kOldWMPPlugin[] = _T("npdsplay.dll"); 44 static const TCHAR kOldWMPPlugin[] = _T("npdsplay.dll");
45 static const TCHAR kYahooApplicationStatePlugin[] = _T("npystate.dll");
45 static const TCHAR kRegistryJava[] = 46 static const TCHAR kRegistryJava[] =
46 _T("Software\\JavaSoft\\Java Runtime Environment"); 47 _T("Software\\JavaSoft\\Java Runtime Environment");
47 static const TCHAR kRegistryBrowserJavaVersion[] = _T("BrowserJavaVersion"); 48 static const TCHAR kRegistryBrowserJavaVersion[] = _T("BrowserJavaVersion");
48 static const TCHAR kRegistryCurrentJavaVersion[] = _T("CurrentVersion"); 49 static const TCHAR kRegistryCurrentJavaVersion[] = _T("CurrentVersion");
49 static const TCHAR kRegistryJavaHome[] = _T("JavaHome"); 50 static const TCHAR kRegistryJavaHome[] = _T("JavaHome");
50 51
51 // Extra registry paths to search. 52 // Extra registry paths to search.
52 static std::vector<std::wstring>* extra_plugin_paths_ = NULL; 53 static std::vector<std::wstring>* extra_plugin_paths_ = NULL;
53 54
54 PluginList* PluginList::Singleton() { 55 PluginList* PluginList::Singleton() {
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
183 if (!SupportsType(mime_type)) 184 if (!SupportsType(mime_type))
184 plugins_.push_back(new_plugin); 185 plugins_.push_back(new_plugin);
185 } 186 }
186 } 187 }
187 188
188 bool PluginList::ShouldLoadPlugin(const std::wstring& filename) { 189 bool PluginList::ShouldLoadPlugin(const std::wstring& filename) {
189 // Depends on XPCOM. 190 // Depends on XPCOM.
190 if (filename == kMozillaActiveXPlugin) 191 if (filename == kMozillaActiveXPlugin)
191 return false; 192 return false;
192 193
194 // Disable the yahoo application state plugin as it crashes the plugin
195 // process on return from NPObjectStub::OnInvoke. Please refer to
196 // http://b/issue?id=1372124 for more information.
197 if (filename == kYahooApplicationStatePlugin)
198 return false;
199
193 // We will use activex shim to handle embeded wmp media. 200 // We will use activex shim to handle embeded wmp media.
194 if (use_internal_activex_shim_) { 201 if (use_internal_activex_shim_) {
195 if (filename == kNewWMPPlugin || filename == kOldWMPPlugin) 202 if (filename == kNewWMPPlugin || filename == kOldWMPPlugin)
196 return false; 203 return false;
197 } else { 204 } else {
198 // If both the new and old WMP plugins exist, only load the new one. 205 // If both the new and old WMP plugins exist, only load the new one.
199 if (filename == kNewWMPPlugin) { 206 if (filename == kNewWMPPlugin) {
200 if (dont_load_new_wmp_) 207 if (dont_load_new_wmp_)
201 return false; 208 return false;
202 209
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after
478 RegKey key(root_key, reg_path.c_str()); 485 RegKey key(root_key, reg_path.c_str());
479 486
480 std::wstring path; 487 std::wstring path;
481 if (key.ReadValue(kRegistryPath, &path)) 488 if (key.ReadValue(kRegistryPath, &path))
482 LoadPlugin(path); 489 LoadPlugin(path);
483 } 490 }
484 } 491 }
485 492
486 } // namespace NPAPI 493 } // namespace NPAPI
487 494
OLDNEW
« 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