Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Don't align ALI block size to 4 byte boundary
ALI blocks are used in two locations inside a PSD file: - At the end of each Layer Info section. These ALI blocks describe properties of each layer. Although Adobe does not name these fields, I call them "Extra Info Blocks". - After the Global Layer Mask Info section. These are called "Tagged Blocks", and appear to describe properties of the entire PSD file. It is known that AdditionalLayerInfo (ALI) blocks are aligned to a multiple 4 bytes. (This is undocumented in Adobe's docs). However, we discovered that this only applies to Tagged Blocks, but not Extra Info Blocks. This caused some PSD files to fail to parse because we were wrongly enforcing the 4-byte alignment on Extra Info Blocks. Since our library only parses Extra Info Blocks (completely skipping Tagged Blocks), we can simply remove the 4-byte aligment code for now. This issue was reported by @immigration9
- Loading branch information