upleb.uk

Public git repos — served from a NIP-34 GRASP relay at git.upleb.uk

summaryrefslogtreecommitdiff
path: root/runtime/src/thread_stacks.cpp
diff options
context:
space:
mode:
authorbobcatchris <83428450+bobcatchris@users.noreply.github.com>2026-11-22 04:45:30 -0600
committerbobcatchris <83428450+bobcatchris@users.noreply.github.com>2026-11-22 04:45:30 -0600
commitc20cb27807f0acbaa34a5736770f9c452582fe6a (patch)
tree18a442496691784439978d2a1179a560f59b2eae /runtime/src/thread_stacks.cpp
parentf85582e23d4ab9e19acbf694358f137d6b8531b1 (diff)
tile_probe/amd_swizzle: a preview must not overwrite the blob it probed
`--out` is written by PIL with no checks: pointing it at the blob being probed opened the sample for the read and then saved the preview over it, truncating the very bytes the probe had just read (`tile_probe shot.bin --out shot.bin` leaves shot.bin as a PNG). A folder that did not exist was a PIL traceback after the whole probe had already run, and a Pillow install in the --user site is invisible to the documented `python -I` invocation, which was a ModuleNotFoundError from inside render() at the same late point. The path checks now run before the read: refuse a directory, refuse the input (realpath plus samefile, so a different spelling of the same file is caught), create the preview's folder, and give Pillow's absence one line at render time. amd_swizzle imports the same helper for its own preview.
Diffstat (limited to 'runtime/src/thread_stacks.cpp')
0 files changed, 0 insertions, 0 deletions