Changeset 260864 in webkit


Ignore:
Timestamp:
Apr 28, 2020 9:26:12 PM (4 years ago)
Author:
ddkilzer@apple.com
Message:

REGRESSION (r260407): Over-release of NSGraphicsContext in WebKit::convertPlatformImageToBitmap()
<https://webkit.org/b/211160>

Reviewed by Darin Adler.

  • UIProcess/Cocoa/WebPageProxyCocoa.mm:

(WebKit::convertPlatformImageToBitmap): Use retainPtr() instead
of adoptNS() to fix the over-release.

Location:
trunk/Source/WebKit
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebKit/ChangeLog

    r260861 r260864  
     12020-04-28  David Kilzer  <ddkilzer@apple.com>
     2
     3        REGRESSION (r260407): Over-release of NSGraphicsContext in WebKit::convertPlatformImageToBitmap()
     4        <https://webkit.org/b/211160>
     5
     6        Reviewed by Darin Adler.
     7
     8        * UIProcess/Cocoa/WebPageProxyCocoa.mm:
     9        (WebKit::convertPlatformImageToBitmap): Use retainPtr() instead
     10        of adoptNS() to fix the over-release.
     11
    1122020-04-28  David Kilzer  <ddkilzer@apple.com>
    213
  • trunk/Source/WebKit/UIProcess/Cocoa/WebPageProxyCocoa.mm

    r260611 r260864  
    406406    UIGraphicsPopContext();
    407407#elif PLATFORM(MAC)
    408     auto savedContext = adoptNS([NSGraphicsContext currentContext]);
     408    auto savedContext = retainPtr([NSGraphicsContext currentContext]);
    409409
    410410    [NSGraphicsContext setCurrentContext:[NSGraphicsContext graphicsContextWithCGContext:graphicsContext->platformContext() flipped:YES]];
Note: See TracChangeset for help on using the changeset viewer.