Changeset 227932 in webkit
- Timestamp:
- Jan 31, 2018 2:40:10 PM (6 years ago)
- Location:
- trunk/Source/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebCore/ChangeLog
r227928 r227932 1 2018-01-31 Youenn Fablet <youenn@apple.com> 2 3 Change SWServer::claim to set the iterator value as soon as possible 4 https://bugs.webkit.org/show_bug.cgi?id=182337 5 6 Reviewed by Chris Dumez. 7 8 No change of behavior, this is a "let's go safe way" fix. 9 10 * workers/service/server/SWServer.cpp: 11 (WebCore::SWServer::claim): 12 1 13 2018-01-31 Zalan Bujtas <zalan@apple.com> 2 14 -
trunk/Source/WebCore/workers/service/server/SWServer.cpp
r227796 r227932 421 421 auto result = m_clientToControllingWorker.add(clientData.identifier, worker.identifier()); 422 422 if (!result.isNewEntry) { 423 if (result.iterator->value == worker.identifier()) 423 auto previousIdentifier = result.iterator->value; 424 if (previousIdentifier == worker.identifier()) 424 425 return; 425 if (auto* controllingRegistration = registrationFromServiceWorkerIdentifier(result.iterator->value)) 426 result.iterator->value = worker.identifier(); 427 if (auto* controllingRegistration = registrationFromServiceWorkerIdentifier(previousIdentifier)) 426 428 controllingRegistration->removeClientUsingRegistration(clientData.identifier); 427 result.iterator->value = worker.identifier();428 429 } 429 430 registration->controlClient(clientData.identifier);
Note: See TracChangeset
for help on using the changeset viewer.