mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:37:43 +00: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
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