Changeset 140081 in webkit


Ignore:
Timestamp:
Jan 17, 2013 6:09:21 PM (11 years ago)
Author:
jonlee@apple.com
Message:

Do not track user interaction for plugins that are not snapshotted
https://bugs.webkit.org/show_bug.cgi?id=107211
<rdar://problem/12967277>

Reviewed by Dean Jackson.

When the user interacts with a snapshotted plug-in, we extend that plug-in origin's
expiration date. However, plug-ins may not be snapshotted for other reasons than the
user's initial opt-in. In this case, that plug-in's origin might be not be in the cached
table. This is an edge case that was not initially considered.

  • WebProcess/WebProcess.cpp:

(WebKit::WebProcess::plugInDidReceiveUserInteraction): Convert the assertion to an if
check, and return early if the entry is not found in the cache table.

Location:
trunk/Source/WebKit2
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit2/ChangeLog

    r140054 r140081  
     12013-01-17  Jon Lee  <jonlee@apple.com>
     2
     3        Do not track user interaction for plugins that are not snapshotted
     4        https://bugs.webkit.org/show_bug.cgi?id=107211
     5        <rdar://problem/12967277>
     6
     7        Reviewed by Dean Jackson.
     8
     9        When the user interacts with a snapshotted plug-in, we extend that plug-in origin's
     10        expiration date. However, plug-ins may not be snapshotted for other reasons than the
     11        user's initial opt-in. In this case, that plug-in's origin might be not be in the cached
     12        table. This is an edge case that was not initially considered.
     13
     14        * WebProcess/WebProcess.cpp:
     15        (WebKit::WebProcess::plugInDidReceiveUserInteraction): Convert the assertion to an if
     16        check, and return early if the entry is not found in the cache table.
     17
    1182013-01-17  Alexey Proskuryakov  <ap@apple.com>
    219
  • trunk/Source/WebKit2/WebProcess/WebProcess.cpp

    r139257 r140081  
    817817
    818818    HashMap<unsigned, double>::iterator it = m_plugInAutoStartOrigins.find(plugInOriginHash);
    819     ASSERT(it != m_plugInAutoStartOrigins.end());
     819    if (it == m_plugInAutoStartOrigins.end())
     820        return;
    820821    if (it->value - currentTime() > plugInAutoStartExpirationTimeUpdateThreshold)
    821822        return;
Note: See TracChangeset for help on using the changeset viewer.