Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: cb01f4ca942d355c84e1c6248560cf63a58ebfd0
      
https://github.com/WebKit/WebKit/commit/cb01f4ca942d355c84e1c6248560cf63a58ebfd0
  Author: Youenn Fablet <[email protected]>
  Date:   2022-11-29 (Tue, 29 Nov 2022)

  Changed paths:
    M Source/WebCore/Modules/streams/ReadableStreamInternals.js
    M Source/WebCore/bindings/js/JSDOMGlobalObject.cpp
    M Source/WebCore/bindings/js/WebCoreBuiltinNames.h
    M Source/WebCore/dom/AbortSignal.cpp
    M Source/WebCore/dom/AbortSignal.h
    M Source/WebCore/dom/AbortSignal.idl

  Log Message:
  -----------
  ReadableStream::pipeTo memory leak
https://bugs.webkit.org/show_bug.cgi?id=247618
rdar://problem/102366716

Reviewed by Alex Christensen.

Before the patch, a reference to pipeState would be kept in the AbortSignal.
We are now removing the algorithm from thr AbortSignal when finalizing pipeTo 
to break the reference cycle.

* Source/WebCore/Modules/streams/ReadableStreamInternals.js:
(readableStreamPipeToWritableStream):
(pipeToFinalize):
* Source/WebCore/bindings/js/JSDOMGlobalObject.cpp:
(WebCore::JSC_DEFINE_HOST_FUNCTION):
(WebCore::JSDOMGlobalObject::addBuiltinGlobals):
* Source/WebCore/bindings/js/WebCoreBuiltinNames.h:
* Source/WebCore/dom/AbortSignal.cpp:
(WebCore::AbortSignal::signalAbort):
(WebCore::AbortSignal::addAbortAlgorithmToSignal):
(WebCore::AbortSignal::removeAbortAlgorithmFromSignal):
(WebCore::AbortSignal::addAlgorithm):
(WebCore::AbortSignal::removeAlgorithm):
(WebCore::AbortSignal::whenSignalAborted): Deleted.
* Source/WebCore/dom/AbortSignal.h:
* Source/WebCore/dom/AbortSignal.idl:

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


_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to