xquartz: fix compilation

Fixes #1788

Fixes: 21df7a77d ("xquartz: fix length checking with bigreq")

Part-of: <https://gitlab.freedesktop.org/xorg/xserver/-/merge_requests/1777>
(cherry picked from commit da0de21b72)
This commit is contained in:
Aki Sakurai 2025-02-09 10:11:52 +08:00 committed by Alan Coopersmith
parent d54c1e6c44
commit a49a8a3cf9

View file

@ -387,7 +387,7 @@ ProcAppleWMSetWindowMenu(register ClientPtr client)
return BadAlloc;
}
max_len = (client->req-len << 2) - sizeof(xAppleWMSetWindowMenuReq);
max_len = (client->req_len << 2) - sizeof(xAppleWMSetWindowMenuReq);
bytes = (char *)&stuff[1];
for (i = j = 0; i < max_len && j < nitems;) {