mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-09 17:44:56 +09:00
LibGfx/ILBM: Explicitly fail decoding if body chunk isn't present
Previously, the decoder would crash in this case.
This commit is contained in:
parent
cb961101c7
commit
f4a89c31c6
Notes:
sideshowbarker
2024-07-17 17:06:59 +09:00
Author: https://github.com/tcl3
Commit: f4a89c31c6
Pull-request: https://github.com/SerenityOS/serenity/pull/21465
1 changed files with 3 additions and 0 deletions
|
@ -289,6 +289,9 @@ static ErrorOr<void> decode_iff_chunks(ILBMLoadingContext& context)
|
|||
}
|
||||
}
|
||||
|
||||
if (context.state != ILBMLoadingContext::State::BitmapDecoded)
|
||||
return Error::from_string_literal("Missing body chunk");
|
||||
|
||||
return {};
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue