mirror of
https://github.com/withastro/astro.git
synced 2024-12-30 22:03:56 -05:00
Fix JPEG image size determination (#12542)
This commit is contained in:
parent
f71052df01
commit
65e50eb7b6
2 changed files with 7 additions and 1 deletions
5
.changeset/bright-pants-trade.md
Normal file
5
.changeset/bright-pants-trade.md
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
'astro': patch
|
||||||
|
---
|
||||||
|
|
||||||
|
Fix JPEG image size determination
|
|
@ -122,7 +122,8 @@ export const JPG: IImage = {
|
||||||
|
|
||||||
// Every JPEG block must begin with a 0xFF
|
// Every JPEG block must begin with a 0xFF
|
||||||
if (input[i] !== 0xff) {
|
if (input[i] !== 0xff) {
|
||||||
input = input.slice(1)
|
// Change from upstream: fix non-0xFF blocks skipping
|
||||||
|
input = input.slice(i)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue