Changeset 83769 in webkit


Ignore:
Timestamp:
Apr 13, 2011 2:38:21 PM (13 years ago)
Author:
sfalken@apple.com
Message:

2011-04-13 Steve Falkenburg <sfalken@apple.com>

Reviewed by Oliver Hunt.

WebKit2 will load two copies of the same plugin, but should not
https://bugs.webkit.org/show_bug.cgi?id=49075
<rdar://problem/8635947>

  • UIProcess/Plugins/win/PluginInfoStoreWin.cpp: (WebKit::PluginInfoStore::shouldUsePlugin): Don't use a plug-in if we've already allowed a plug-in with the same filename.
Location:
trunk/Source/WebKit2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r83768 r83769  
     12011-04-13  Steve Falkenburg  <sfalken@apple.com>
     2
     3        Reviewed by Oliver Hunt.
     4
     5        WebKit2 will load two copies of the same plugin, but should not
     6        https://bugs.webkit.org/show_bug.cgi?id=49075
     7        <rdar://problem/8635947>
     8
     9        * UIProcess/Plugins/win/PluginInfoStoreWin.cpp:
     10        (WebKit::PluginInfoStore::shouldUsePlugin): Don't use a plug-in if we've already allowed a plug-in with the same filename.
     11
    1122011-04-13  Timothy Hatcher  <timothy@apple.com>
    213
  • trunk/Source/WebKit2/UIProcess/Plugins/win/PluginInfoStoreWin.cpp

    r81989 r83769  
    340340bool PluginInfoStore::shouldUsePlugin(const Plugin& plugin)
    341341{
    342     // FIXME: We should prefer a newer version of a plugin to an older version, rather than loading
    343     // both. <http://webkit.org/b/49075>
    344 
    345342    if (plugin.info.name == "Citrix ICA Client") {
    346343        // The Citrix ICA Client plug-in requires a Mozilla-based browser; see <rdar://6418681>.
     
    394391    }
    395392
     393    // FIXME: We should prefer a newer version of a plugin to an older version, rather than loading
     394    // only the first. <http://webkit.org/b/58469>
     395    String pluginPath = plugin.path;
     396    String pluginFileName(::PathFindFileNameW(pluginPath.charactersWithNullTermination()));
     397    for (size_t i = 0; i < m_plugins.size(); ++i) {
     398        Plugin& loadedPlugin = m_plugins[i];
     399
     400        // If a plug-in with the same filename already exists, we don't want to load it.
     401        String loadedPluginFileName(::PathFindFileNameW(loadedPlugin.path.charactersWithNullTermination()));
     402        if (equalIgnoringCase(pluginFileName, loadedPluginFileName))
     403            return false;
     404    }
     405
    396406    return true;
    397407}
Note: See TracChangeset for help on using the changeset viewer.