Skip to content

Fix raster exception from malformed WebP images#107

Merged
lucianbc merged 1 commit intomainfrom
lucianbc/fix-raster-exception
Apr 8, 2026
Merged

Fix raster exception from malformed WebP images#107
lucianbc merged 1 commit intomainfrom
lucianbc/fix-raster-exception

Conversation

@lucianbc
Copy link
Copy Markdown
Member

@lucianbc lucianbc commented Apr 8, 2026

Some WebP images cannot be parsed by the ImageIO plug in. They probably have a malformed frame header, but the actual rendering algorithm handles this issue gracefully and can still draw the images. Howerver, the memory footprint tool crashes for such images. When such an exception occurs, we can avoid crashing by assuming the frame is fully white, which may lead to a bigger memory footprint, but the watch face may still pass the check, or fail with a known error.

@lucianbc lucianbc requested a review from garanj April 8, 2026 13:36
@lucianbc lucianbc force-pushed the lucianbc/fix-raster-exception branch 2 times, most recently from ddbab05 to 0051068 Compare April 8, 2026 13:51
Some WebP images cannot be parsed by the ImageIO plug in. They probably
have a malformed frame header, but the actual rendering algorithm
handles this issue gracefully and can still draw the images. Howerver,
the memory footprint tool crashes for such images. When such an
exception occurs, we can avoid crashing by assuming the frame is fully
white, which may lead to a bigger memory footprint, but the watch face
may still pass the check, or fail with a known error.
@lucianbc lucianbc force-pushed the lucianbc/fix-raster-exception branch from 0051068 to 5b98f7d Compare April 8, 2026 14:08
@lucianbc lucianbc requested a review from robcos April 8, 2026 14:39
@lucianbc lucianbc merged commit 6b314c6 into main Apr 8, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants