diff options
| author | 2023-04-25 21:32:02 -0400 | |
|---|---|---|
| committer | 2023-04-25 21:32:02 -0400 | |
| commit | f98ab7aaca3c4acbd5a793267791749740330e9c (patch) | |
| tree | 72e3d3312a8ff2cdb24353b1d7be6fb8301f431c /gallery_dl/downloader/http.py | |
| parent | 09e426350409d45e7f7a8ff369f8d8aa9eec0fe4 (diff) | |
New upstream version 1.25.2.upstream/1.25.2
Diffstat (limited to 'gallery_dl/downloader/http.py')
| -rw-r--r-- | gallery_dl/downloader/http.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gallery_dl/downloader/http.py b/gallery_dl/downloader/http.py index e977320..88e86e9 100644 --- a/gallery_dl/downloader/http.py +++ b/gallery_dl/downloader/http.py @@ -353,6 +353,8 @@ MIME_TYPES = { "image/x-ms-bmp": "bmp", "image/webp" : "webp", "image/avif" : "avif", + "image/heic" : "heic", + "image/heif" : "heif", "image/svg+xml" : "svg", "image/ico" : "ico", "image/icon" : "ico", @@ -399,6 +401,8 @@ SIGNATURE_CHECKS = { "webp": lambda s: (s[0:4] == b"RIFF" and s[8:12] == b"WEBP"), "avif": lambda s: s[4:11] == b"ftypavi" and s[11] in b"fs", + "heic": lambda s: (s[4:10] == b"ftyphe" and s[10:12] in ( + b"ic", b"im", b"is", b"ix", b"vc", b"vm", b"vs")), "svg" : lambda s: s[0:5] == b"<?xml", "ico" : lambda s: s[0:4] == b"\x00\x00\x01\x00", "cur" : lambda s: s[0:4] == b"\x00\x00\x02\x00", |
