Repository navigation
Refuse cut-short KTX textures instead of decoding them - #2895
Merged
Merged
Conversation
The ASTC decoder returned a full-size picture with no error for short data, and a cut tiled file was read in raster order. AAPL textures are now accepted only at the two measured lengths (linear, or the tiled surface plus one block) and at exactly the tiled surface when HEAD word 12 is 1, a length not seen in any file. A chunk shorter than it declares is refused, and a Khronos KTX texture must hold the whole image. liblzfse.error is turned into ValueError in both readers, so a truncated LZFS snapshot no longer stops the artifact. App Snapshots and Widgets leave it out with a log line; the ATX artifacts list it with a warning. Fixes #2894. Fixes #2890. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Valid and short KTX 1.1 fixtures, raw and Compression_APPLE. The LZFSE compress call goes through one helper so lint stays clean. Co-Authored-By: Claude Opus 5.5 <[email protected]>
abrignoni
added a commit
to charpy4n6/leapps-website
that referenced
this pull request
Nov 25, 2026
Add #2895 to the list of changes, explain that a cut-short snapshot is now refused (no row in App Snapshots or Widgets, a "Left out" log line, a failed-decode row in Messages previews), rewrite the tiling steps to the accepted sizes, re-pin the code link to the merge, and say which changes a build needs for both zig-zags. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Cut-short KTX snapshots no longer become a full-size picture or stop the artifact. Fixes #2894 and #2890.
liblzfse.errornow becomesValueError. A made-up truncated LZFS snapshot used to leave App Snapshots with 0 rows; it is now left out with a log line.🤖 Generated with Claude Code


Confidence Score: 5/5 
The PR appears safe to merge, with the previous test gap addressed and no new actionable issues found.Summary
Refuses incomplete KTX textures before decoding and turns LZFSE failures into handled
ValueErrorexceptions.Reviews (2) · Last reviewed commit: "Test the Khronos KTX length checks" · Reviewed by Greptile