[webkit-reviews] review requested: [Bug 178882] Implement ServiceWorkerContainer getRegistration : [Attachment 325119] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Oct 27 15:22:08 PDT 2017


youenn fablet <youennf at gmail.com> has asked  for review:
Bug 178882: Implement ServiceWorkerContainer getRegistration
https://bugs.webkit.org/show_bug.cgi?id=178882

Attachment 325119: Patch

https://bugs.webkit.org/attachment.cgi?id=325119&action=review




--- Comment #14 from youenn fablet <youennf at gmail.com> ---
Comment on attachment 325119
  --> https://bugs.webkit.org/attachment.cgi?id=325119
Patch

Putting as r?

View in context: https://bugs.webkit.org/attachment.cgi?id=325119&action=review

> Source/WebCore/workers/service/ServiceWorkerContainer.cpp:190
> +

Not necessary, but we could probably call hasServiceWorkerRegisteredForOrigin
check here to do some early null return.
I'll add it as a follow-up or at landing.

>> Source/WebCore/workers/service/server/SWServer.cpp:288
>> +	return selectedRegistration &&
!selectedRegistration->isUninstallingFlagSet() ? selectedRegistration :
nullptr;
> 
> Should we check !selectedRegistration->isEmpty() too?

I am not sure, it seems isEmpty is private and should not be called on the main
thread.


More information about the webkit-reviews mailing list