Closed Bug 1813466 Opened 2 years ago Closed 2 years ago

Crash when disabling AVIF animation support while being used in a page

Categories

(Core :: Graphics: ImageLib, defect)

Firefox 111
defect

Tracking

()

VERIFIED FIXED
113 Branch
Tracking Status
firefox-esr102 --- unaffected
firefox111 --- wontfix
firefox112 --- wontfix
firefox113 --- verified
firefox114 --- verified

People

(Reporter: ke5trel, Assigned: Zaggy1024)

References

(Regression, )

Details

(Keywords: crash, regression)

Attachments

(1 file)

STR:

  1. Set image.avif.sequence.enabled = true.
  2. Visit https://anilist.co/activity/132716060.
  3. Set image.avif.sequence.enabled = false while the page is still open.

Crash report: https://crash-stats.mozilla.org/report/index/c8ecf0d8-44ff-4bed-9a00-238460230130

MOZ_CRASH Reason: MOZ_RELEASE_ASSERT(isSome())

Top 10 frames of crashing thread:

0  libxul.so  mozilla::Maybe<mozilla::image::AnimationParams>::ref const&  mfbt/Maybe.h:801
0  libxul.so  mozilla::image::Decoder::AllocateFrameInternal  image/Decoder.cpp:379
0  libxul.so  mozilla::image::Decoder::AllocateFrame  image/Decoder.cpp:300
1  libxul.so  mozilla::image::SurfaceSink::Configure  image/SurfacePipe.cpp:68
2  libxul.so  mozilla::image::ColorManagementFilter<mozilla::image::SurfaceSink>::Configure<mozilla::image::SurfaceConfig>  image/SurfaceFilters.h:140
2  libxul.so  mozilla::image::SurfacePipeFactory::MakePipe<mozilla::image::ColorManagementConfig, mozilla::image::SurfaceConfig>  image/SurfacePipeFactory.h:665
3  libxul.so  mozilla::image::SurfacePipeFactory::CreateReorientSurfacePipe  image/SurfacePipeFactory.h:632
4  libxul.so  mozilla::image::nsAVIFDecoder::Decode  image/decoders/nsAVIFDecoder.cpp:1715
5  libxul.so  mozilla::image::nsAVIFDecoder::DoDecode  image/decoders/nsAVIFDecoder.cpp:1181
6  libxul.so  mozilla::image::Decoder::Decode  image/Decoder.cpp:177
Crash Signature: [@ const]

We should probably check StaticPrefs::image_avif_sequence_enabled_AtStartup() instead of StaticPrefs::image_avif_sequence_enabled()

Severity: -- → S3

This allows the AVIF decoder to force its parser to animate in cases where the
decoder is recreated after an "image.avif.sequence" pref has been changed to
prevent undefined behavior in the image pipeline.

Assignee: nobody → Zaggy1024
Status: NEW → ASSIGNED
Attachment #9318388 - Attachment description: Bug 1813466 - Tell decoders that they are expected to animate by a flag. r=tnikkel → Bug 1813466 - Force AVIF to animate if it is being redecoded after looping. r=tnikkel
Attachment #9318388 - Attachment description: Bug 1813466 - Force AVIF to animate if it is being redecoded after looping. r=tnikkel → Bug 1813466 - Store AVIF prefs as default decoder flags in RasterImage. r=tnikkel
Pushed by tnikkel@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/9c4684ce7168 Store AVIF prefs as default decoder flags in RasterImage. r=tnikkel
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 113 Branch

Since nightly and release are affected, beta will likely be affected too.
For more information, please visit auto_nag documentation.

Setting wontfix for beta/release, I don't think we want to uplift this. This can only happen if the user is toggling the animated avif pref (which has always been off by default) and there is a warning before toggling any prefs in about:config. If there is a reason to reconsider that please comment.

Set release status flags based on info from the regressing bug 1788119

Reproducible on a 2023-03-14 Nightly build on Windows 10.
Verified as fixed on Firefox 113.0b6(build ID: 20230420180037) and Nightly 114.0a1(build ID: 20230420212414) on Windows 10, Ubuntu 22, macOS 12.

Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: