[PATCH xserver 2/2] glamor: Propagate glamor_fds_from_pixmap error in glamor_fd_from_pixmap
Emil Velikov
emil.l.velikov at gmail.com
Wed May 23 15:57:59 UTC 2018
On 23 May 2018 at 10:43, Michel Dänzer <michel at daenzer.net> wrote:
> From: Michel Dänzer <michel.daenzer at amd.com>
>
> 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 <michel.daenzer at amd.com>
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 <emil.velikov at collabora.com>
-Emil
More information about the xorg-devel
mailing list