On 23 May 2018 at 10:43, Michel Dänzer <[email protected]> wrote:
> From: Michel Dänzer <[email protected]>
>
> glamor_fds_from_pixmap returns 0 on error, but we were treating that as
> success, continuing with uninitialized stride and fd values.
>
> Also bail if the offset isn't 0, same as in dri3_fd_from_pixmap.
>
> Fixes: c8c276c9569b "glamor: Implement PixmapFromBuffers and
>                      BuffersFromPixmap"
> Signed-off-by: Michel Dänzer <[email protected]>

I would suggest a one-liner as below. Smaller patch, plus is reads
easier on my end ;-)

-    if (ret > 1) {
+    if (ret != 1 || offsets[0] != 0) {

Regardless, the series is on point and is
Reviewed-by: Emil Velikov <[email protected]>

-Emil
_______________________________________________
[email protected]: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Reply via email to