mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-31 21:59:21 +00:00
LibPDF: Remove the subroutine length limit for PS1 font programs
A limit of 1024 subroutines seemed like a sensible choice, but some fonts actually do exceed it. We will now only assert that the specified amount is positive.
This commit is contained in:
committed by
Andrew Kaster
parent
4ec01669fc
commit
2b3a41be74
@@ -108,7 +108,7 @@ PDFErrorOr<Vector<ByteBuffer>> PS1FontProgram::parse_subroutines(Reader& reader)
|
||||
return error("Expected array length");
|
||||
|
||||
auto length = TRY(parse_int(reader));
|
||||
VERIFY(length <= 1024);
|
||||
VERIFY(length > 0);
|
||||
|
||||
Vector<ByteBuffer> array;
|
||||
TRY(array.try_resize(length));
|
||||
|
||||
Reference in New Issue
Block a user