Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 4a9fc932842d8047416f9c92551d741cdcaf34fc
      
https://github.com/WebKit/WebKit/commit/4a9fc932842d8047416f9c92551d741cdcaf34fc
  Author: Said Abou-Hallawa <s...@apple.com>
  Date:   2024-04-11 (Thu, 11 Apr 2024)

  Changed paths:
    M Source/WebCore/platform/graphics/BitmapImageSource.cpp
    M Source/WebCore/platform/graphics/BitmapImageSource.h

  Log Message:
  -----------
  REGRESSION (276827@main): BitmapImageSource may outlive its creator 
BitmapImage
https://bugs.webkit.org/show_bug.cgi?id=272486
rdar://126113651

Reviewed by Simon Fraser.

Before 276827@main ImageSource used to hold a raw pointer BitmapImage and it had
function to clear this pointer when BitmapImage is destroyed.
Moreover ImageSource methods used to check the nullability of this pointer 
before
using it.

A similar life time relationship needs to be applied to BitmapImageSource and
BitmapImage.

* Source/WebCore/platform/graphics/BitmapImageSource.cpp:
(WebCore::BitmapImageSource::BitmapImageSource):
(WebCore::BitmapImageSource::decoder const):
(WebCore::BitmapImageSource::encodedDataStatusChanged):
(WebCore::BitmapImageSource::decodedSizeChanged):
(WebCore::BitmapImageSource::canDestroyDecodedData const):
(WebCore::BitmapImageSource::resetData):
(WebCore::BitmapImageSource::isAnimationAllowed const):
(WebCore::BitmapImageSource::imageFrameAtIndexAvailable):
(WebCore::BitmapImageSource::imageObserver const):
(WebCore::BitmapImageSource::mimeType const):
(WebCore::BitmapImageSource::expectedContentLength const):
(WebCore::BitmapImageSource::sourceUTF8 const):
* Source/WebCore/platform/graphics/BitmapImageSource.h:

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



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to