]> git.maquefel.me Git - brevno-suite/hugo/commit
resources/images: Don't trust the file extension when decoding JPEG and PNG images
authorBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Thu, 18 Dec 2025 11:00:20 +0000 (12:00 +0100)
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>
Thu, 18 Dec 2025 18:36:48 +0000 (19:36 +0100)
commit65d43e1d0de86dcae84a468817c46cc02470c8b3
tree22f1d7c00c8e07aa99cfebd3cdb964b737513a95
parent65a76664e3279b585437148860148cbaad6c2d57
resources/images: Don't trust the file extension when decoding JPEG and PNG images

Which is it behaved before we added the extended WebP support.

Testing on some sites shows that it's not uncommon to store JPEGs with PNG extensions and vice versa.
This an error situation that needs to be reported, but let us push that to a future Hugo version to reduce the noise in this one.
resources/images/codec.go