mirror of
https://github.com/storytold/vectorcraft.git
synced 2026-11-29 17:54:36 +01:00
The private data streams of a .ai file, or of a PDF saved with its editing data, were joined into one buffer of at most 256 MiB before they were decoded, while the decoded editing data may take up to an eighth of installed memory (512 MiB to 2 GiB). A file whose streams passed 256 MiB opened as its PDF part without a note, and a file whose PDF part can't be read failed with "it is larger than 256 MB". The streams are now read one after the other and decoded as they are read, so they are never joined. The decoded data keeps its limit, and no more of the streams is read than that limit and a sixteenth more. The data is decompressed after the first compression marker in it.