mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-01-12 18:26:17 +03:00
Merge pull request #7483 from radarhere/psd
This commit is contained in:
commit
7e30619541
BIN
Tests/images/five_channels.psd
Normal file
BIN
Tests/images/five_channels.psd
Normal file
Binary file not shown.
|
@ -111,6 +111,11 @@ def test_rgba():
|
|||
assert_image_equal_tofile(im, "Tests/images/imagedraw_square.png")
|
||||
|
||||
|
||||
def test_layer_skip():
|
||||
with Image.open("Tests/images/five_channels.psd") as im:
|
||||
assert im.n_frames == 1
|
||||
|
||||
|
||||
def test_icc_profile():
|
||||
with Image.open(test_file) as im:
|
||||
assert "icc_profile" in im.info
|
||||
|
|
|
@ -186,6 +186,9 @@ def _layerinfo(fp, ct_bytes):
|
|||
ct_types = i16(read(2))
|
||||
types = list(range(ct_types))
|
||||
if len(types) > 4:
|
||||
fp.seek(len(types) * 6 + 12, io.SEEK_CUR)
|
||||
size = i32(read(4))
|
||||
fp.seek(size, io.SEEK_CUR)
|
||||
continue
|
||||
|
||||
for _ in types:
|
||||
|
|
Loading…
Reference in New Issue
Block a user