libnvidia-egl-wayland/0005-Use-INT32_MAX-for-wl_surface_damage.patch

28 lines
948 B
Diff

From febf851acc9c6a9a067ec001104533777adb5572 Mon Sep 17 00:00:00 2001
From: Kyle Brenneman <kbrenneman@nvidia.com>
Date: Tue, 27 Aug 2024 08:17:20 -0600
Subject: [PATCH 5/9] Use INT32_MAX for wl_surface_damage
The wl_surface_damage request takes signed integer parameters, so
sending UINT32_MAX would be received as -1. Instead, send INT32_MAX.
---
src/wayland-eglsurface.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/wayland-eglsurface.c b/src/wayland-eglsurface.c
index c2e3fdc..4e4dcff 100644
--- a/src/wayland-eglsurface.c
+++ b/src/wayland-eglsurface.c
@@ -301,7 +301,7 @@ wlEglSendDamageEvent(WlEglSurface *surface,
wl_surface_damage_buffer(surface->wlSurface, rect[0], inv_y, rect[2], rect[3]);
}
} else {
- wl_surface_damage(surface->wlSurface, 0, 0, UINT32_MAX, UINT32_MAX);
+ wl_surface_damage(surface->wlSurface, 0, 0, INT32_MAX, INT32_MAX);
}
--
2.43.0