1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 16:07:46 +00:00

LibGfx: Make TextDescriptionTagData verify input is 7-bit ASCII

TextDescriptionTagData::from_bytes() errors out if that isn't the case,
but let's make sure other potential future callers get it right too.
This commit is contained in:
Nico Weber 2023-02-18 21:30:50 -05:00 committed by Jelle Raaijmakers
parent e76f1caf79
commit b2cf773d85

View file

@ -732,6 +732,8 @@ public:
, m_unicode_description(move(unicode_description))
, m_macintosh_description(move(macintosh_description))
{
for (u8 byte : ascii_description.bytes())
VERIFY(byte < 128);
}
// Guaranteed to be 7-bit ASCII.