[webkit-changes] [WebKit/WebKit] ede746: Cherry-pick a8076cd43460. rdar://problem/103277903

Miguel Salinas noreply at github.com
Wed Dec 14 10:49:24 PST 2022


  Branch: refs/heads/safari-7615.1.15-branch
  Home:   https://github.com/WebKit/WebKit
  Commit: ede746697144a8262812484a30012a4d9cd344a5
      https://github.com/WebKit/WebKit/commit/ede746697144a8262812484a30012a4d9cd344a5
  Author: Kimmo Kinnunen <kkinnunen at apple.com>
  Date:   2022-12-14 (Wed, 14 Dec 2022)

  Changed paths:
    M LayoutTests/TestExpectations
    A LayoutTests/webgl/webgl-fail-platform-context-creation-no-crash-expected.txt
    A LayoutTests/webgl/webgl-fail-platform-context-creation-no-crash.html
    M Source/WTF/Scripts/Preferences/WebPreferencesInternal.yaml
    M Source/WebCore/html/canvas/WebGLContextAttributes.idl
    M Source/WebCore/platform/graphics/GraphicsContextGLAttributes.h
    M Source/WebCore/platform/graphics/angle/GraphicsContextGLANGLE.cpp
    M Source/WebKit/GPUProcess/graphics/RemoteGraphicsContextGL.cpp
    M Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in
    M Tools/WebKitTestRunner/TestOptions.cpp

  Log Message:
  -----------
  Cherry-pick a8076cd43460. rdar://problem/103277903

    RemoteGraphicsContextGL crashes if platform graphics context creation fails
    https://bugs.webkit.org/show_bug.cgi?id=249214
    rdar://103277903

    Reviewed by Matt Woodrow.

    Creating GraphicsContextGL would fail if ANGLE shared library is not present.
    This is as intended, on macOS this happens in recovery OS.
    GPUP RemoteGraphicsContextGL would access nullptr when the unusable context
    would be destroyed.

    Guard for the nullptr context.
    Move the IPC stream connection opening in the functions that execute on
    stream work queue and start receiving messages from the stream only when
    the context creation succeeds. This way the payload functions do not need
    the nullptr guard, which they do not have.

    * Source/WTF/Scripts/Preferences/WebPreferencesInternal.yaml:
    * Source/WebCore/html/canvas/WebGLContextAttributes.idl:
    * Source/WebCore/platform/graphics/GraphicsContextGLAttributes.h:
    * Source/WebCore/platform/graphics/angle/GraphicsContextGLANGLE.cpp:
    (WebCore::GraphicsContextGLANGLE::initialize):
    * Source/WebKit/GPUProcess/graphics/RemoteGraphicsContextGL.cpp:
    (WebKit::RemoteGraphicsContextGL::initialize):
    (WebKit::RemoteGraphicsContextGL::stopListeningForIPC):
    (WebKit::RemoteGraphicsContextGL::workQueueInitialize):
    (WebKit::RemoteGraphicsContextGL::workQueueUninitialize):
    * Source/WebKit/Shared/WebCoreArgumentCoders.serialization.in:
    * Tools/WebKitTestRunner/TestOptions.cpp:
    (WTR::TestOptions::defaults):

    Canonical link: https://commits.webkit.org/257843@main

Canonical link: https://commits.webkit.org/257698.4@safari-7615.1.15-branch


  Commit: 0300a46661c56c6087eff3660a27a98b00a5b085
      https://github.com/WebKit/WebKit/commit/0300a46661c56c6087eff3660a27a98b00a5b085
  Author: Miguel Salinas <miguel_salinas at apple.com>
  Date:   2022-12-14 (Wed, 14 Dec 2022)

  Changed paths:
    M Source/WebKit/UIProcess/ProcessThrottler.cpp

  Log Message:
  -----------
  Cherry-pick 9bdfab144ce0. rdar://problem/103276264

    [iOS] Fix crash in ProcessThrottler::sendPrepareToSuspendIPC
    https://bugs.webkit.org/show_bug.cgi?id=249220
    rdar://103276264

    Reviewed by Chris Dumez.

    After 257628 at main we call `ProcessThrottler::updateThrottleStateIfNeeded`
    every time we call `ProcessThrottler::setShouldTakeSuspendedAssertion`.
    Instead, we should only take or drop the Suspended assertion when actually
    needed in `ProcessThrottler::setShouldTakeSuspendedAssertion`.

    * Source/WebKit/UIProcess/ProcessThrottler.cpp:
    (WebKit::ProcessThrottler::setShouldTakeSuspendedAssertion):

    Canonical link: https://commits.webkit.org/257850@main

Canonical link: https://commits.webkit.org/257698.5@safari-7615.1.15-branch


Compare: https://github.com/WebKit/WebKit/compare/7dd03fcb7285...0300a46661c5


More information about the webkit-changes mailing list