mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-24 03:44:06 +00:00
Xext: add __size_assert in xvdisp.c
See: https://github.com/X11Libre/xserver/pull/1021 See: https://github.com/X11Libre/xserver/issues/706 Signed-off-by: stefan11111 <stefan11111@shitposting.expert>
This commit is contained in:
committed by
Enrico Weigelt
parent
765d0de418
commit
dbfd395b28
@@ -765,6 +765,7 @@ ProcXvQueryImageAttributes(ClientPtr client)
|
||||
|
||||
/* allocating for `offsets` as well as `pitches` in one block */
|
||||
/* both having CARD32 * num_planes (actually int32_t put into CARD32) */
|
||||
__size_assert(int, sizeof(INT32));
|
||||
int *offsets = x_rpcbuf_reserve(&rpcbuf, 2 * num_planes * sizeof(int));
|
||||
if (!offsets)
|
||||
return BadAlloc;
|
||||
|
||||
Reference in New Issue
Block a user