<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[224944] trunk</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/224944">224944</a></dd>
<dt>Author</dt> <dd>cdumez@apple.com</dd>
<dt>Date</dt> <dd>2017-11-16 16:45:06 -0800 (Thu, 16 Nov 2017)</dd>
</dl>

<h3>Log Message</h3>
<pre>Dispatching an event on a ServiceWorkerRegistration may fail or crash due to GC
https://bugs.webkit.org/show_bug.cgi?id=179751

Reviewed by Geoffrey Garen.

Source/WebCore:

Dispatching an event on a ServiceWorkerRegistration may fail or crash due to GC. We
need to make sure that a ServiceWorkerRegistration's wrapper stays alive as long as
we may dispatch events on it.

Keep the wrapper alive by making ServiceWorker an ActiveDOMObject and making sure the
implementation object keeps a PendingActivity alive while it may dispatch JS events.
The only event dispatched on ServiceWorkerRegistration objects is the "updatefound"
one. We may dispatch updatefound events on a ServiceWorkerRegistration until the
registration gets cleared on server side, in which case the ServiceWorkerRegistration
object ends up with no service worker. We therefore take a PendingActivity when the
ServiceWorkerRegistration is constructed and we release it once the registration has
no more associated ServiceWorker or the ActiveDOMObject is stopped (to avoid leaks on
navigation).

Test: http/tests/workers/service/service-worker-registration-gc-event.html

* workers/service/ServiceWorkerContainer.cpp:
(WebCore::ServiceWorkerContainer::scheduleTaskToFireUpdateFoundEvent):
* workers/service/ServiceWorkerRegistration.cpp:
(WebCore::ServiceWorkerRegistration::getOrCreate):
(WebCore::ServiceWorkerRegistration::updateStateFromServer):
(WebCore::ServiceWorkerRegistration::scheduleTaskToFireUpdateFoundEvent):
(WebCore::ServiceWorkerRegistration::stop):
(WebCore::ServiceWorkerRegistration::updatePendingActivityForEventDispatch):
* workers/service/ServiceWorkerRegistration.h:
* workers/service/ServiceWorkerRegistration.idl:

LayoutTests:

Add layout test coverage.

* http/tests/workers/service/service-worker-registration-gc-event-expected.txt: Added.
* http/tests/workers/service/service-worker-registration-gc-event.html: Added.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkLayoutTestsChangeLog">trunk/LayoutTests/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreworkersserviceServiceWorkerContainercpp">trunk/Source/WebCore/workers/service/ServiceWorkerContainer.cpp</a></li>
<li><a href="#trunkSourceWebCoreworkersserviceServiceWorkerRegistrationcpp">trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.cpp</a></li>
<li><a href="#trunkSourceWebCoreworkersserviceServiceWorkerRegistrationh">trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.h</a></li>
<li><a href="#trunkSourceWebCoreworkersserviceServiceWorkerRegistrationidl">trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.idl</a></li>
</ul>

<h3>Added Paths</h3>
<ul>
<li><a href="#trunkLayoutTestshttptestsworkersserviceserviceworkerregistrationgceventexpectedtxt">trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event-expected.txt</a></li>
<li><a href="#trunkLayoutTestshttptestsworkersserviceserviceworkerregistrationgceventhtml">trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event.html</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkLayoutTestsChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/LayoutTests/ChangeLog (224943 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/ChangeLog      2017-11-17 00:35:51 UTC (rev 224943)
+++ trunk/LayoutTests/ChangeLog 2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -1,3 +1,15 @@
</span><ins>+2017-11-16  Chris Dumez  <cdumez@apple.com>
+
+        Dispatching an event on a ServiceWorkerRegistration may fail or crash due to GC
+        https://bugs.webkit.org/show_bug.cgi?id=179751
+
+        Reviewed by Geoffrey Garen.
+
+        Add layout test coverage.
+
+        * http/tests/workers/service/service-worker-registration-gc-event-expected.txt: Added.
+        * http/tests/workers/service/service-worker-registration-gc-event.html: Added.
+
</ins><span class="cx"> 2017-11-16  Matt Lewis  <jlewis3@apple.com>
</span><span class="cx"> 
</span><span class="cx">         Marked svg/wicd/test-rightsizing-a.xhtml as flaky.
</span></span></pre></div>
<a id="trunkLayoutTestshttptestsworkersserviceserviceworkerregistrationgceventexpectedtxt"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event-expected.txt (0 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event-expected.txt                           (rev 0)
+++ trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event-expected.txt      2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -0,0 +1,3 @@
</span><ins>+updatefound event fired
+updatefound event fired
+
</ins></span></pre></div>
<a id="trunkLayoutTestshttptestsworkersserviceserviceworkerregistrationgceventhtml"></a>
<div class="addfile"><h4>Added: trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event.html (0 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event.html                           (rev 0)
+++ trunk/LayoutTests/http/tests/workers/service/service-worker-registration-gc-event.html      2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -0,0 +1,25 @@
</span><ins>+<!DOCTYPE html>
+<html>
+<head>
+<script src="resources/sw-test-pre.js"></script>
+</head>
+<body>
+<script>
+let updatefoundCount = 0;
+
+navigator.serviceWorker.register("resources/empty.js", { }).then(function(registration) {
+    registration.addEventListener("updatefound", function() {
+        gc();
+        log("updatefound event fired");
+        updatefoundCount++;
+        if (updatefoundCount == 2)
+            finishSWTest();
+    });
+    registration.update();
+    setTimeout(function() {
+        gc();
+    }, 0);
+});
+</script>
+</body>
+</html>
</ins></span></pre></div>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (224943 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog   2017-11-17 00:35:51 UTC (rev 224943)
+++ trunk/Source/WebCore/ChangeLog      2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -1,5 +1,39 @@
</span><span class="cx"> 2017-11-16  Chris Dumez  <cdumez@apple.com>
</span><span class="cx"> 
</span><ins>+        Dispatching an event on a ServiceWorkerRegistration may fail or crash due to GC
+        https://bugs.webkit.org/show_bug.cgi?id=179751
+
+        Reviewed by Geoffrey Garen.
+
+        Dispatching an event on a ServiceWorkerRegistration may fail or crash due to GC. We
+        need to make sure that a ServiceWorkerRegistration's wrapper stays alive as long as
+        we may dispatch events on it.
+
+        Keep the wrapper alive by making ServiceWorker an ActiveDOMObject and making sure the
+        implementation object keeps a PendingActivity alive while it may dispatch JS events.
+        The only event dispatched on ServiceWorkerRegistration objects is the "updatefound"
+        one. We may dispatch updatefound events on a ServiceWorkerRegistration until the
+        registration gets cleared on server side, in which case the ServiceWorkerRegistration
+        object ends up with no service worker. We therefore take a PendingActivity when the
+        ServiceWorkerRegistration is constructed and we release it once the registration has
+        no more associated ServiceWorker or the ActiveDOMObject is stopped (to avoid leaks on
+        navigation).
+
+        Test: http/tests/workers/service/service-worker-registration-gc-event.html
+
+        * workers/service/ServiceWorkerContainer.cpp:
+        (WebCore::ServiceWorkerContainer::scheduleTaskToFireUpdateFoundEvent):
+        * workers/service/ServiceWorkerRegistration.cpp:
+        (WebCore::ServiceWorkerRegistration::getOrCreate):
+        (WebCore::ServiceWorkerRegistration::updateStateFromServer):
+        (WebCore::ServiceWorkerRegistration::scheduleTaskToFireUpdateFoundEvent):
+        (WebCore::ServiceWorkerRegistration::stop):
+        (WebCore::ServiceWorkerRegistration::updatePendingActivityForEventDispatch):
+        * workers/service/ServiceWorkerRegistration.h:
+        * workers/service/ServiceWorkerRegistration.idl:
+
+2017-11-16  Chris Dumez  <cdumez@apple.com>
+
</ins><span class="cx">         Crash in WebCore::SWServerJobQueue::scriptFetchFinished(WebCore::SWServer::Connection&, WebCore::ServiceWorkerFetchResult const&) + 77
</span><span class="cx">         https://bugs.webkit.org/show_bug.cgi?id=179394
</span><span class="cx">         <rdar://problem/35478190>
</span></span></pre></div>
<a id="trunkSourceWebCoreworkersserviceServiceWorkerContainercpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/workers/service/ServiceWorkerContainer.cpp (224943 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/workers/service/ServiceWorkerContainer.cpp  2017-11-17 00:35:51 UTC (rev 224943)
+++ trunk/Source/WebCore/workers/service/ServiceWorkerContainer.cpp     2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -293,16 +293,8 @@
</span><span class="cx"> 
</span><span class="cx"> void ServiceWorkerContainer::scheduleTaskToFireUpdateFoundEvent(ServiceWorkerRegistrationIdentifier identifier)
</span><span class="cx"> {
</span><del>-    if (isStopped())
-        return;
-
-    scriptExecutionContext()->postTask([this, protectedThis = makeRef(*this), identifier](ScriptExecutionContext&) {
-        if (isStopped())
-            return;
-
-        if (auto* registration = m_registrations.get(identifier))
-            registration->dispatchEvent(Event::create(eventNames().updatefoundEvent, false, false));
-    });
</del><ins>+    if (auto* registration = m_registrations.get(identifier))
+        registration->scheduleTaskToFireUpdateFoundEvent();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void ServiceWorkerContainer::jobResolvedWithRegistration(ServiceWorkerJob& job, ServiceWorkerRegistrationData&& data, WTF::Function<void()>&& promiseResolvedHandler)
</span><span class="lines">@@ -311,14 +303,17 @@
</span><span class="cx">         jobDidFinish(job);
</span><span class="cx">     });
</span><span class="cx"> 
</span><del>-    auto* context = scriptExecutionContext();
-    if (!context) {
-        LOG_ERROR("ServiceWorkerContainer::jobResolvedWithRegistration called but the containers ScriptExecutionContext is gone");
</del><ins>+    if (isStopped()) {
</ins><span class="cx">         promiseResolvedHandler();
</span><span class="cx">         return;
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    context->postTask([this, protectedThis = makeRef(*this), job = makeRef(job), data = WTFMove(data), promiseResolvedHandler = WTFMove(promiseResolvedHandler)](ScriptExecutionContext& context) mutable {
</del><ins>+    scriptExecutionContext()->postTask([this, protectedThis = makeRef(*this), job = makeRef(job), data = WTFMove(data), promiseResolvedHandler = WTFMove(promiseResolvedHandler)](ScriptExecutionContext& context) mutable {
+        if (isStopped()) {
+            promiseResolvedHandler();
+            return;
+        }
+
</ins><span class="cx">         auto registration = ServiceWorkerRegistration::getOrCreate(context, *this, WTFMove(data));
</span><span class="cx"> 
</span><span class="cx">         LOG(ServiceWorker, "Container %p resolved job with registration %p", this, registration.ptr());
</span></span></pre></div>
<a id="trunkSourceWebCoreworkersserviceServiceWorkerRegistrationcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.cpp (224943 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.cpp       2017-11-17 00:35:51 UTC (rev 224943)
+++ trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.cpp  2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -29,6 +29,8 @@
</span><span class="cx"> #if ENABLE(SERVICE_WORKER)
</span><span class="cx"> #include "DOMWindow.h"
</span><span class="cx"> #include "Document.h"
</span><ins>+#include "Event.h"
+#include "EventNames.h"
</ins><span class="cx"> #include "Logging.h"
</span><span class="cx"> #include "ServiceWorker.h"
</span><span class="cx"> #include "ServiceWorkerContainer.h"
</span><span class="lines">@@ -39,8 +41,10 @@
</span><span class="cx"> 
</span><span class="cx"> Ref<ServiceWorkerRegistration> ServiceWorkerRegistration::getOrCreate(ScriptExecutionContext& context, Ref<ServiceWorkerContainer>&& container, ServiceWorkerRegistrationData&& data)
</span><span class="cx"> {
</span><del>-    if (auto* registration = container->registration(data.identifier))
</del><ins>+    if (auto* registration = container->registration(data.identifier)) {
+        ASSERT(!registration->m_isStopped);
</ins><span class="cx">         return *registration;
</span><ins>+    }
</ins><span class="cx"> 
</span><span class="cx">     return adoptRef(*new ServiceWorkerRegistration(context, WTFMove(container), WTFMove(data)));
</span><span class="cx"> }
</span><span class="lines">@@ -61,6 +65,9 @@
</span><span class="cx">         m_activeWorker = ServiceWorker::getOrCreate(context, WTFMove(*m_registrationData.activeWorker));
</span><span class="cx"> 
</span><span class="cx">     m_container->addRegistration(*this);
</span><ins>+
+    relaxAdoptionRequirement();
+    updatePendingActivityForEventDispatch();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> ServiceWorkerRegistration::~ServiceWorkerRegistration()
</span><span class="lines">@@ -161,8 +168,23 @@
</span><span class="cx">         m_activeWorker = WTFMove(serviceWorker);
</span><span class="cx">         break;
</span><span class="cx">     }
</span><ins>+    updatePendingActivityForEventDispatch();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void ServiceWorkerRegistration::scheduleTaskToFireUpdateFoundEvent()
+{
+    if (m_isStopped)
+        return;
+
+    scriptExecutionContext()->postTask([this, protectedThis = makeRef(*this)](ScriptExecutionContext&) {
+        if (m_isStopped)
+            return;
+
+        ASSERT(m_pendingActivityForEventDispatch);
+        dispatchEvent(Event::create(eventNames().updatefoundEvent, false, false));
+    });
+}
+
</ins><span class="cx"> EventTargetInterface ServiceWorkerRegistration::eventTargetInterface() const
</span><span class="cx"> {
</span><span class="cx">     return ServiceWorkerRegistrationEventTargetInterfaceType;
</span><span class="lines">@@ -180,9 +202,28 @@
</span><span class="cx"> 
</span><span class="cx"> bool ServiceWorkerRegistration::canSuspendForDocumentSuspension() const
</span><span class="cx"> {
</span><ins>+    // FIXME: We should do better as this prevents a page from entering PageCache when there is a service worker registration.
</ins><span class="cx">     return !hasPendingActivity();
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+void ServiceWorkerRegistration::stop()
+{
+    m_isStopped = true;
+    updatePendingActivityForEventDispatch();
+}
+
+void ServiceWorkerRegistration::updatePendingActivityForEventDispatch()
+{
+    // If a registration has no ServiceWorker, then it has been cleared on server-side.
+    if (m_isStopped || !getNewestWorker()) {
+        m_pendingActivityForEventDispatch = nullptr;
+        return;
+    }
+    if (m_pendingActivityForEventDispatch)
+        return;
+    m_pendingActivityForEventDispatch = makePendingActivity(*this);
+}
+
</ins><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> #endif // ENABLE(SERVICE_WORKER)
</span></span></pre></div>
<a id="trunkSourceWebCoreworkersserviceServiceWorkerRegistrationh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.h (224943 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.h 2017-11-17 00:35:51 UTC (rev 224943)
+++ trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.h    2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -65,9 +65,11 @@
</span><span class="cx">     const ServiceWorkerRegistrationData& data() const { return m_registrationData; }
</span><span class="cx"> 
</span><span class="cx">     void updateStateFromServer(ServiceWorkerRegistrationState, RefPtr<ServiceWorker>&&);
</span><ins>+    void scheduleTaskToFireUpdateFoundEvent();
</ins><span class="cx"> 
</span><span class="cx"> private:
</span><span class="cx">     ServiceWorkerRegistration(ScriptExecutionContext&, Ref<ServiceWorkerContainer>&&, ServiceWorkerRegistrationData&&);
</span><ins>+    void updatePendingActivityForEventDispatch();
</ins><span class="cx"> 
</span><span class="cx">     EventTargetInterface eventTargetInterface() const final;
</span><span class="cx">     ScriptExecutionContext* scriptExecutionContext() const final;
</span><span class="lines">@@ -74,8 +76,10 @@
</span><span class="cx">     void refEventTarget() final { ref(); }
</span><span class="cx">     void derefEventTarget() final { deref(); }
</span><span class="cx"> 
</span><ins>+    // ActiveDOMObject.
</ins><span class="cx">     const char* activeDOMObjectName() const final;
</span><span class="cx">     bool canSuspendForDocumentSuspension() const final;
</span><ins>+    void stop() final;
</ins><span class="cx"> 
</span><span class="cx">     ServiceWorkerRegistrationData m_registrationData;
</span><span class="cx">     Ref<ServiceWorkerContainer> m_container;
</span><span class="lines">@@ -83,6 +87,9 @@
</span><span class="cx">     RefPtr<ServiceWorker> m_installingWorker;
</span><span class="cx">     RefPtr<ServiceWorker> m_waitingWorker;
</span><span class="cx">     RefPtr<ServiceWorker> m_activeWorker;
</span><ins>+
+    bool m_isStopped { false };
+    RefPtr<PendingActivity<ServiceWorkerRegistration>> m_pendingActivityForEventDispatch;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> } // namespace WebCore
</span></span></pre></div>
<a id="trunkSourceWebCoreworkersserviceServiceWorkerRegistrationidl"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.idl (224943 => 224944)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.idl       2017-11-17 00:35:51 UTC (rev 224943)
+++ trunk/Source/WebCore/workers/service/ServiceWorkerRegistration.idl  2017-11-17 00:45:06 UTC (rev 224944)
</span><span class="lines">@@ -27,6 +27,7 @@
</span><span class="cx"> // We don't currently support nested workers.
</span><span class="cx"> 
</span><span class="cx"> [
</span><ins>+    ActiveDOMObject,
</ins><span class="cx">     SecureContext,
</span><span class="cx">     Exposed=(Window),
</span><span class="cx">     Conditional=SERVICE_WORKER,
</span></span></pre>
</div>
</div>

</body>
</html>