egl/wayland: fix oob buffer access during buffer_fds clean up
authorDavid Redondo <kde@david-redondo.de>
Fri, 14 Apr 2023 09:47:43 +0000 (11:47 +0200)
committerMarge Bot <emma+marge@anholt.net>
Mon, 17 Apr 2023 09:02:53 +0000 (09:02 +0000)
commiteb7e9068865e312a0efb5c863d0d3be6e7571d8d
treeda0ba79debc4432e2ebe9e7fdef56004f3a5de21
parent0d7912d239dac5bf3c8b07f2a6ca467f760d6aa6
egl/wayland: fix oob buffer access during buffer_fds clean up

After iterating through the number of planes in the above for
loop i is more than the number of planes which corresponds to
the size of the buffer_fds array.

Fixes: 967b9ad084e ("egl/wayland: for prime, allocate linear_copy from display GPU VRAM")
Signed-off-by: David Redondo <kde@david-redondo.de>
Reviewed-by: Simon Ser <contact@emersion.fr>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22496>
src/egl/drivers/dri2/platform_wayland.c