Repository navigation
[0.4.x] Plugins (JESS): Fix 8-bit blur without MMX - #433
Conversation
The non-MMX 8-bit loop uses bmax without initializing it, which can iterate beyond the pixel buffer and crash. Move the existing assignment before the MMX/non-MMX branch so both paths use the same initialized bound.
|
This fix is now in Debian testing and unstable, with successful builds and autopkgtests on all eight release architectures. Could you please review it when you have a chance? Thanks! |
There was a problem hiding this comment.
@fmolara thanks for bringing this up! I find that the 0.5.x master branch agrees with this idea…
…and for some reason branch 0.4.x did not have this fix backported.
The red CI error…
Invalid configuration '\': machine '\-unknown' not recognized
…is unrelated and not your fault. I have taken care of it just now via PR #435 and expect 0.4.x to be all-green after a rebase-merge of your pull request here.
Thank you!
|
As a note, |
|
Thanks for the reference, and apologies for overlooking your original fix. I should have checked the history of master before preparing this patch for 0.4.x. |
The scalar 8-bit blur loop uses an uninitialized upper bound: render_blur()
assigns bmax only inside the MMX branch, although the non-MMX branch also
uses it to stop iterating over the pixel buffer. This can run past the
buffer and crash while rendering an 8-bit surface.
Move the existing assignment before the MMX/non-MMX branch so both paths
use the same initialized bound. The loop and bound calculation are
otherwise unchanged.
Validation with a headless libvisual client rendering 16 frames into a
320x240 8-bit surface, fed with synthetic stereo audio:
QEMU. GDB identifies the scalar loop at renderer.c:421.
native amd64 and sh4/QEMU.
the failing case to the 8-bit path.
This targets 0.4.x and changes only the JESS renderer.
CI status: all four Linux/macOS build-and-test jobs and the help-output
check pass. The translation-sync job stops during the core configure
step with "Invalid configuration '\'", before catalog comparison. Its
translations.yml has a trailing backslash on the final --prefix line;
that workflow is unchanged between the fork base and current 0.4.x.
No workflow or catalog files are changed by this PR.