[PATCH] xace: Fix XaceCensorImage to actually censor the right part of the image
michel at daenzer.net
Thu Aug 18 02:09:01 UTC 2016
On 16/08/16 02:12 AM, Adam Jackson wrote:
> On Tue, 2016-08-02 at 10:34 -0700, Aaron Plattner wrote:
>> The caller passes arguments into XaceCensorImage that are in window-relative
>> coordinates. However, the pBuf that it uses to construct a temporary pixmap has
>> its origin at (x, y) relative to the window in question. The code to convert the
>> censor region into boxes adjusts for the Y coordinate, but leaves the X
>> coordinate alone. The result is that if x is not zero, it censors the wrong part
>> of the image.
>> Fix this by just translating censorRegion into pixmap-relative coordinates and
>> using the resulting boxes as-is.
>> Reported-by: Fabien Lelaquais <Fabien.Lelaquais at roguewave.com>
>> Link: https://lists.x.org/archives/xorg/2016-August/058165.html
>> Signed-off-by: Aaron Plattner <aplattner at nvidia.com>
> Nice find.
> remote: I: patch #102574 updated using rev 92b3cd32066aa5befa67a408cc079cd2ce4c077e.
> remote: I: 1 patch(es) updated to state Accepted.
> To ssh://git.freedesktop.org/git/xorg/xserver
> 4d58611..92b3cd3 master -> master
Unfortunately, this broke two XTS tests:
xts5 at xlib9@xgetimage at 7
xts5 at xlib9@xgetsubimage at 7
Earthling Michel Dänzer | http://www.amd.com
Libre software enthusiast | Mesa and X developer
More information about the xorg-devel