Skip to content
Commit 979a87b9 authored by Bert Pauline's avatar Bert Pauline Committed by Emmanuele Bassi
Browse files

gdk-pixbuf-xlib: Fix out-of-bounds error in dithering loop

Use two loops to traverse the array of arrays `DM`, i.e. use `DM[y][x]`
instead of `DM[0][i]`.

This resolves a warning about undefined behavior when compiling with GCC
with aggressive loop optimizations enabled.

While we are at it: Move the variable definitions into the body of the
outer if-statement.

https://bugzilla.gnome.org/show_bug.cgi?id=748211
parent 87f8f4bf
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment