[webkit-reviews] review granted: [Bug 185722] Safari optimized flow should be releasing viewer to prevent memory growth with subsequent launches/closes : [Attachment 340570] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu May 17 04:21:13 PDT 2018


David Kilzer (:ddkilzer) <ddkilzer at webkit.org> has granted Dean Jackson
<dino at apple.com>'s request for review:
Bug 185722: Safari optimized flow should be releasing viewer to prevent memory
growth with subsequent launches/closes
https://bugs.webkit.org/show_bug.cgi?id=185722

Attachment 340570: Patch

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




--- Comment #3 from David Kilzer (:ddkilzer) <ddkilzer at webkit.org> ---
Comment on attachment 340570
  --> https://bugs.webkit.org/attachment.cgi?id=340570
Patch

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

r=me

> Source/WebKit/UIProcess/Cocoa/SystemPreviewControllerCocoa.mm:90
> +    WebKit::WeakObjCPtr<_WKPreviewControllerDataSource> weakSelf { self };

FWIW, as of Bug 184789 / r230824, you can start using __weak directly.	Not
sure how well that plays with C++ lambdas, though.

> Source/WebKit/UIProcess/Cocoa/SystemPreviewControllerCocoa.mm:93
> +	   auto strongSelf = weakSelf.get();
> +	   if (strongSelf)

Nit: Could use:

	if ((auto strongSelf = weakSelf.get()))


More information about the webkit-reviews mailing list